-
Notifications
You must be signed in to change notification settings - Fork 442
OBS Minor Release HOWTO
Table of Contents
- How do we do minor releases?
This is a documentation about updating OBS from X.Y.Z to X.Y.(Z+1) (so let's say from 2.8.0 to 2.8.1).
For the rest of this document:
-
$VERSION
: refers to 2.8 -
$NEW_MINOR_VERSION
: refers to 2.8.1
The main reason to publish a new minor release is to fix some security bug, sometimes reported internally by the security team. Check the issue handling procedure.
The first step is trying to reproduce the error in the code we maintain: master and the latest release which is X.Y.Z (e.g. 2.10.8). The possible scenarios are:
Reproducible on master | Reproducible on the latest release | What should you do? |
---|---|---|
Yes | Yes | Try to find a solution for both master and the latest released version of the code. |
Yes | No | It can be a "regression", open an issue on GitHub, its priority will probably increase. |
No | Yes | Try to find what solved the problem on master, try to apply a similar solution to the latest release. |
No | No | Inform that the user is probably running a no longer maintained version of the code. |
Download the most recent appliance from Open Build Service and run it in a Virtual Machine. The OBS Apliance guide can help you.
If the issue, usually reported via Bugzilla, is reproducible in the latest release and we consider that should be fixed in the appliance, then we have to publish a new minor release.
Before that, we have to ask the security team to allocate a new CVE number for us. This is an example of an existing CVE. The new CVE should be mentioned in the release notes of the new version.
Once you know what the problem is, collect patches for the new release. You have to open a Pull Request with the changes towards the correct branch. For example, if the latest release is X.Y.Z (e.g. 2.8.0), the corresponding branch is X.Y (e.g. 2.8).
- Commit the changes to the corresponding git version branch.
- Add a
ReleaseNotes-$NEW_MINOR_VERSION
file in the root of the git repository. - In the release notes file, mention any important change / bug fix made since the last release. Also mention the newly allocated CVE number if any.
The PR should pass all the CI tests, but the code should also pass the OpenQA tests. This guide can help you to run OpenQA smoke tests locally.
You found a solution, your PR was merged and all sort of tests passed.
The next step is to update obs-server
package inside OBS:Server:X.Y:Staging (e.g. OBS:Server:2.8:Staging) and see if it still builds for all the distributions. Follow the next steps to do so:
-
Check out the obs-server package
OBS:Server:$VERSION:Staging
and move into its directory:osc co OBS:Server:$VERSION:Staging obs-server cd OBS:Server:$VERSION:Staging/obs-server
-
Change the
version
inside the_service
file to$NEW_MINOR_VERSION
(e.g. 2.8.1). Leave therevision
value as the branch name (e.g. 2.8):<service name="obs_scm"> <param name="version">$NEW_MINOR_VERSION</param> <param name="revision">2.8</param> ... </service>
-
Run
osc vc obs-server.changes
and paste theReleaseNotes-$NEW_MINOR_VERSION
file. -
Run
osc ci
soOBS:Server:$VERSION:Staging / obs-server
will start building again. -
Watch the package
obs-server
to succeed for all distributions.
-
Inside the package OBS:Server:$VERSION:Staging/OBS-Appliance, edit the file
OBS-Appliance.kiwi
(you can do it via WebUI). There, set all the version tags to$NEW_MINOR_VERSION
:<version>$NEW_MINOR_VERSION</version> ... <version>$NEW_MINOR_VERSION</version>
-
Watch the package
OBS-Appliance
to succeed for all distributions.
The newly created OBS:Server:$VERSION:Staging
appliances are automatically tested by openQA. Make sure the tests succeed!
You can also check that the new version appears on http://download.opensuse.org/repositories/OBS:/Server:/$VERSION:/Staging/images/
.
-
osc co OBS-Appliance-vmdk
- (If you use VirtualBox, use vdi format from OBS 2.7 on!)
osc getbinaries images
- Start the .vmdk / .vdi file in Virtual box:
- NOTE: if you use
VirtualBox
remember to configure your network asBridged Adapter
. - Test that apache & buildservice starts automatically.
- Test your changes work and have not introduced any regression:
- Create an Interconnect to openSUSE.org.
- Create the
Admin:home
project. - Branch from Interconnect
openSUSE.org:openSUSE:Tools/build
package. - Add build targets to the project and watch package build.
- NOTE: if you use
All steps so far only affect Staging. Before you move forward, ensure that all the tests passed and all the builds succeded. Now you are about to really publish the new minor release.
Release the staging project with:
osc release --no-delay OBS:Server:$VERSION:Staging
This command simply copies all the sources and binaries from OBS:Server:$VERSION:Staging
to OBS:Server:$VERSION
. That behaviour is specified in the releasetarget
tag inside the meta file of OBS:Server:$VERSION:Staging. Example:
<repository name="openSUSE_15.2">
<releasetarget project="OBS:Server:2.10" repository="openSUSE_15.2" trigger="manual"/>
...
</repository>
The --no-delay
option will make the command to run immediately the release, and wait for a result. Otherwise there is no way to know if it has finished or didn't start yet.
Wait until the Staging project gets released. You can check that the new version appears on http://download.opensuse.org/repositories/OBS:/Server:/$VERSION/images/
.
Write a mail like this to our public mailing list.
git fetch upstream
git checkout upstream/$VERSION
git tag -a $NEW_MINOR_VERSION
git push upstream $NEW_MINOR_VERSION
In the past, we had some problems when we used the same name for a git branch and for a git tag. To avoid conflicts, ensure you never create tags with the format X.Y (for example 2.10), they are reserved for branches. The tags should always look like X.Y.Z. Summarizing:
- branch 2.10: OK.
- tag 2.10: WRONG!
- tag 2.10.0: OK.
- Development Environment Overview
- Development Environment Tips & Tricks
- Spec-Tips
- Code Style
- Rubocop
- Testing with VCR
- 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
- next_rails
- Ruby Update
- Rails Profiling
- Installing a local LDAP-server
- 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
- How to Introduce Software Design Patterns
- Query Objects
- Services
- View Components
- RFC: Core Components
- RFC: Decorator Pattern
- RFC: Backend models