-
Notifications
You must be signed in to change notification settings - Fork 461
OBS Major Release HOWTO
A major OBS release usually involves a couple of iterations of releases until we release the official, new major release. This starts with an development version (alpha), continues with one or more beta releases and ends with the final 2.x release.
To make the different stages of this workflow visible to others it's recommended to add a -alpha, -beta1, -beta2 suffix to the $VERSION of our appliances and obs-server package.
Before we can do the first beta release, we need to create and set up various projects in OBS, openQA, etc. All this is explained below.
- Create a new branch for the release, eg. '2.9'
- Protect the git version branch
- Go to the 'Settings' tab
- Select 'Branches' from the list menu
- Choose the newly created branch
- Enable the 'Protect this branch' checkbox and save
- Commit the changes to the git version branch
- Add a new ReleaseNotes-$VERSION file in the root of the git version branch
- Go to the hakiri configuration page.
- Click on 'Follow Branch' button for the newly, created branch.
-
Get our stable project meta example.
wget https://raw.githubusercontent.com/openSUSE/open-build-service/master/dist/stable_project_meta.xml.example -
Adapt the example file. Basically replace
$VERSIONwith the major version and check that the openSUSE/SLE versions it builds against are the latest ones. -
Create the project using the meta file
osc meta prj -e OBS:Server:$VERSION:Staging -F stable_project_meta.xml.example
-
Get our staging project meta example.
wget https://raw.githubusercontent.com/openSUSE/open-build-service/master/dist/staging_project_meta.xml.example -
Adapt the example file:
- Replace
$VERSIONwith the major version and check that the openSUSE/SLE versions it builds against are the latest ones. - Change the project description to reflect that this is a development project (or an alpha/beta release):
This is the development version 2.9 of OBS. - Replace
-
Create the project using the meta file
osc meta prj -e OBS:Server:$VERSION:Staging -F staging_project_meta.xml.example -
Copy the prjconf file from OBS:Server:Unstable and apply the needed modification
osc meta prjconf OBS:Server:Unstable > prjconf_$VERSION -
Apply the current prjconf
osc meta prjconf OBS:Server:$VERSION:Staging -F prjconf_$VERSION -
Adjust the project conf, eg. remove checks for repositories and architectures we don't support in our stable release.
-
At least we will need the following packages to build obs-server correctly
deltarpm libarchive libmemcached memcached perl-BSSolv perl-Devel-Cover perl-common-sense perl-Diff-LibXDiff perl-File-Sync perl-GD perl-JSON-XS perl-Socket-MsgHdr phantomjs containment-rpm-docker obs-signd createrepo build ruby-common ruby2.4 rubygem-bundler rubygem-gem2rpm rubygem-hoe rubygem-rake-compiler yum sphinx travis-deps nodejs obs-server
-
Copy those packages from
Unstableosc copypac OBS:Server:Unstable $PACKAGE OBS:Server:$VERSION:Staging
-
Checkout obs-server package to have it locally
osc co OBS:Server:$VERSION:Staging obs-server -
Change the
versionformatandrevisioninside the _service file to $VERSION<service name="obs_scm" mode="disabled"> <param name="versionformat">$VERSION~pre.git%cd.%h</param> <param name="revision">$VERSION</param> ... </service>
-
Copy the changelog file from the previous version. So for example, for 2.9 we use 2.8:
osc cat OBS:Server:2.8 obs-server obs-server.changes > obs-server.changes osc addremove -
Create a changelog entry from the ReleaseNotes-$VERSION file:
osc vc obs-server.changes -
Check in the changes and make it build
osc ci osc r -v OBS:Server:$VERSION:Staging obs-server
-
Get an list of rubygem package dependencies:
docker-compose run --rm --no-deps frontend script/rubygem_package_names.rb > rubygem_dependencies.txt -
Use that list to copy those dependencies from the Unstable project:
for PACKAGE in `cat rubygem_dependencies.txt`; do osc copypac OBS:Server:Unstable $PACKAGE OBS:Server:$VERSION:Staging; done
-
At least we will need the following packages, and its dependencies, to build obs-server correctly:
OBS-Appliance OBS-Appliance-docker OBS-Appliance-qcow2 OBS-Appliance-vdi OBS-Appliance-vmdk apache2-mod_xforward changelog-generator-data rubygem-passenger rubygem-changelog-generator -
Copy the appliance packages from
Unstable:osc copypac OBS:Server:Unstable $PACKAGE OBS:Server:$VERSION:Staging
-
Checkout the
OBS-Appliancepackage:osc co OBS:Server:$VERSION:Staging OBS-Appliance -
Set the version tag inside the
OBS-Appliance.kiwifile to$VERSION:<version>$VERSION</version> -
Set the version in the repository section inside the
config.shfile with the correct$VERSION:#====================================== # Add Default Repositories #-------------------------------------- zypper ar http://download.opensuse.org/distribution/leap/42.3/repo/oss/ openSUSE:Leap:42.3 ... zypper ar http://download.opensuse.org/repositories/OBS:/Server:/$VERSION/openSUSE_42.3/ OBS:Server:$VERSION
-
Check in the changes and make it build:
osc ci osc r -v OBS:Server:$VERSION:Staging OBS-Appliance
-
Add a new "Medium type" in openqa.opensuse.org with the name of the new version. You need admin rigths in openQA. For example, for version 2.9:
Distri Version Flavor Arch Settings Actions obs 2.9 Appliance x86_64 -
Add a new line to (or adjust) the dist/schedule-obs.sh script with the new version to be tested. Have a look at openQA-Setup for locating the script.
-
In our openQA setup we currently install some packages from
OBS:Server:$VERSION. To make sure that these packages are available runosc release OBS:Server:$VERSION:Staging.
- Download the built appliance and test LDAP support as described in our wiki.
As mentioned before, there probably will be multiple (beta) releases before we do the final release. All these releases follow the same steps, with small differences.
Let's say you want to release the beta 1 for OBS 2.9. Your version would then be '2.9.0-beta1'.
For the obs-server package you would edit the _service file:
<param name="versionformat">2.9.0-beta1~pre.git%cd.%h</param>For our OBS-Appliances you would edit the config.xml of the OBS-Appliances package. This will affect all OBS-Appliances-* sub-packages:
<version>2.9.0-beta1</version>-
Release the staging project with
osc release OBS:Server:$VERSION:Staging- Wait until the staging project gets released.
-
Write a mail like this to our public mailing list.
-
[optional] Write a blog post for our blog.
-
Tag the released code. Add a
-betasuffix for beta releases.git fetch upstream git checkout upstream/$VERSION git tag -a $NEW_VERSION git push upstream $VERSION --tags
-
Update description of OBS:Server:$VERSION.
- Development Environment Overview
- Development Environment Tips & Tricks
- Spec-Tips
- Code Style
- Rubocop
- Testing with VCR
- Test in kanku
- Authentication
- Authorization
- Autocomplete
- BS Requests
- Events
- ProjectLog
- Notifications
- Feature Toggles
- Build Results
- Attrib classes
- Flags
- The BackendPackage Cache
- Maintenance classes
- Cloud uploader
- Delayed Jobs
- Staging Workflow
- StatusHistory
- OBS API
- Owner Search
- Search
- Links
- Distributions
- Repository
- Data Migrations
- Package Versions
- next_rails
- Ruby Update
- Rails Profiling
- Remote Pairing Setup Guide
- Factory Dashboard
- osc
- Setup an OBS Development Environment on macOS
- Run OpenQA smoketest locally
- Responsive Guidelines
- Importing database dumps
- Problem Statement & Solution
- Kickoff New Stuff
- New Swagger API doc
- Documentation and Communication
- GitHub Actions
- Brakeman
- How to Introduce Software Design Patterns
- Query Objects
- Services
- View Components
- RFC: Core Components
- RFC: Decorator Pattern
- RFC: Backend models
- RFC: Hotwire Turbo Frames Pattern