Feature #3009

nethserver-devbox replacements

Added by Davide Principi over 6 years ago. Updated over 6 years ago.

Status:CLOSEDStart date:
Priority:NormalDue date:
Assignee:-% Done:

100%

Category:<multiple packages>
Target version:v6.6-rc1
Resolution: NEEDINFO:No

Description

Two new experimental packages are available to solve nethserver-devbox issues.
  • nethserver-mock, for RPM building
  • nethserver-createiso, for ISO building

The new tools use a minimal configuration approach, and should be simpler to set up.


Related issues

Related to NethServer 6 - Bug #2770: Devbox: missing rpmspec command CLOSED
Related to NethServer 6 - Bug #2879: build-rpm error on Fedora 20 CLOSED

Associated revisions

Revision 23a14135
Added by Davide Principi over 6 years ago

Initial version. Refs #3009

Revision 1d0c4292
Added by Davide Principi over 6 years ago

Added NethServer 6.6 configuration. Refs #3009

Revision be99aa4f
Added by Davide Principi over 6 years ago

Allow git tags containing "-" character. Refs #3009

Only last 2 components of `git describe` output are considered.

Revision ae5b892e
Added by Davide Principi over 6 years ago

Insert development changelog from `git log` output. Refs #3009

Revision 8cb2fd91
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 4a9011f1
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 9bac146c
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 2da31495
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 3404cf3f
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 36e6bb4e
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 61047a8a
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 8932e233
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 460fc700
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 2a22bfa8
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 51cdea60
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 54dbdf75
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 27992979
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 10b40208
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision f8139650
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 360686ec
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 692c905b
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision beb66a69
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 2a21177c
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision de40498b
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 7394c454
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision a09dd270
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 83147a15
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 69654502
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 8a19a331
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 1841207a
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 23021a48
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 293ba2bb
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 3bc12c42
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 97a6ad39
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 858d1fdc
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 69dd9be1
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 5ab28617
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 436c5f96
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 0eb573e1
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 41038098
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 5e5a6c58
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 8d1ccea4
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 009b2ae9
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision fa0f9055
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 5437dc04
Added by Giacomo Sanchietti over 6 years ago

spec: move from spec.in to spec. Refs #3009

Revision 0bcee46a
Added by Davide Principi over 6 years ago

New ISO and RPM build scripts. Refs #3009

Revision 378bbc59
Added by Davide Principi over 6 years ago

Fixed Requires tag. Refs #3009

Revision 46479781
Added by Davide Principi over 6 years ago

Added release-tag script. Refs #3009

Revision 1f373268
Added by Davide Principi over 6 years ago

Merge pull request #56 from DavidePrincipi/build-scripts

New ISO and RPM build scripts. Refs #3009

Revision 684362ec
Added by Davide Principi over 6 years ago

Fedora YUM config for building rpms. Refs #3009

History

#1 Updated by Davide Principi over 6 years ago

  • Related to Bug #2770: Devbox: missing rpmspec command added

#2 Updated by Davide Principi over 6 years ago

  • Related to Bug #2879: build-rpm error on Fedora 20 added

#3 Updated by Davide Principi over 6 years ago

  • Target version changed from v6.5 to v6.6-beta1

In nethserver-testing/6.6:
nethserver-createiso-0.0.1-1.ns6.noarch.rpm
nethserver-mock-0.0.1-1.ns6.noarch.rpm

To completely replace and obsolete the old tools, we must
  • complete the RPM workflow with the upload part
  • write the documentation

#4 Updated by Davide Principi over 6 years ago

  • Target version changed from v6.6-beta1 to v6.6-rc1

#5 Updated by Giacomo Sanchietti over 6 years ago

  • Assignee deleted (Davide Principi)

#6 Updated by Davide Principi over 6 years ago

Davide Principi wrote:

To completely replace and obsolete the old tools, we must
  • complete the RPM workflow with the upload part

I added two shell functions to my ~/.bashrc.

This is a simple shell function that uploads RPMs:

function upload-rpms() {
    dest=$1
    shift   
    scp ${*} ${dest}
    host=${dest/%:*/}
    path=${dest##${host}:}
    ssh ${host} "pushd ${path} && make dispatch-rpm && make clean && make && popd" 
}

And this is another function that cleans up the git directory and executes the complete workflow:

function pbuild-rpms() {
    git clean -x -f && make-rpms *.spec && sign-rpms -k MYKEYID -f ~/.secret *.rpm && upload-rpms "$1" *.rpm
}

Assumptions:
  • runs into the project directory
  • cleans up any non-tracked file
  • the project must have only one .spec file
  • any RPM will be uploaded
  • remote repo make will be invoked

Sample invocation:

  pbuild-rpms host:/path/nethserver/6.6/testing

#7 Updated by stephane de Labrusse over 6 years ago

hi all

I have tried nethserver-mock, it is quite good, but it build by default in the repository where it is used, so if you use it in your git repository you can do a mess.
Indeed you can use it outside of your git repository but it is a command line more for changing your place of work.
Could it be possible to add an 'exchange' folder where rpms will be saved, this will be more convenient rather to play with cd command all the time. Of course if you do so, you must give the path where rpms are, so the buildder can copy and pasted with a convenient way to move his rpm.

here the script i use https://github.com/stephdl/git_mockbuild/blob/master/git_mockbuild

#8 Updated by Davide Principi over 6 years ago

stephane de Labrusse wrote:

here the script i use https://github.com/stephdl/git_mockbuild/blob/master/git_mockbuild

Thanks for sharing your script Stephane! I think I'll take the CHANGELOG.git idea on loan ;)

nethserver-mock is different from nethserver-devbox: bare bone vs over-engineered :) The first is somehow process-agnostic (good), the latter is tailored on my personal build infrastructure (no good).

So I think the most important thing in nethserver-mock are the mock config files: I hope they could be useful for other scripts.

Also, to ease package testing, I'd like to set up a public CI environment to automatize package builds in the near future, but this is another thread.

#9 Updated by Giacomo Sanchietti over 6 years ago

  • Target version changed from v6.6-rc1 to v6.6

#10 Updated by Davide Principi over 6 years ago

  • Status changed from TRIAGED to CLOSED
  • Target version changed from v6.6 to v6.6-rc1
  • % Done changed from 20 to 100

In nethserver-base 6.6:
nethserver-createiso-0.0.2-2.ns6.noarch.rpm
nethserver-mock-0.0.4-1.ns6.noarch.rpm

Documentation pull request:
https://github.com/nethesis/nethserver-docs/pull/56

#11 Updated by stephane de Labrusse over 6 years ago

No Problem Davidep, I'm glad to help...

The idea to have a main central build server, is the thing to do.....please go on.

Can we open another bug to get the rpm/srpm in another folder than the git folder ?

#12 Updated by Davide Principi over 6 years ago

stephane de Labrusse wrote:

No Problem Davidep, I'm glad to help...

The idea to have a main central build server, is the thing to do.....please go on.

Sure! I'd like travis-ci or similar.

Can we open another bug to get the rpm/srpm in another folder than the git folder ?

Yep! Why not? Maybe a customizable --resultdir argument to mock is enough...

#13 Updated by stephane de Labrusse over 6 years ago

Indeed or in a folder called exchange in the user home.

Also available in: Atom PDF