-
Notifications
You must be signed in to change notification settings - Fork 51
Home
This is the developer documentation for Salt Developers in openSUSE. For user documentation, please take a look at the upstream docs.
As this repository tracks Salt upstream, openSUSE's Salt developers need to work with more than one Git remote. We use GitHub Pull Requests for contributions, either from forks or other branches in this repository. That results in three or four different remotes:
-
https://github.com/saltstack/salt -
upstream
-
https://github.com/openSUSE/salt -
opensuse
-
https://github.com/<geeko>/salt -
origin
(created by forkingupstream
) -
https://github.com/<geeko>/salt-1 -
opensuse-fork
(created by forkingopensuse
afterwards)
The names of these remotes can be chosen freely, this documentation will use the names that are listed above.
There are generally two reasons for opening a Pull Request: adding a new feature or fixing a bug in the existing code base. In both cases, Pull Requests in this repo (opensuse
) must point to one or more Pull Request(s) @upstream
.
Pull Requests @upstream
must have received positive feedback or been merged before they can be accepted. If upstream
does not agree with a bug fix, try to find a different way that solves the bug. We don't want to carry changes that are not accepted into upstream
.
The opensuse
repository contains branches per Salt version that is packaged at OBS. At the time of writing, there are:
-
openSUSE-3000
(default branch) openSUSE-3002.2
openSUSE-2016.11.10
The default branch is the one of the current version in the latest openSUSE Leap and SUSE Linux Enterprise.
New branches are created by rebasing older patches on top of an upstream
Salt release (marked by a Git tag). From then on, they move independently with us backporting bug fixes from newer releases.
One useful Git feature is git-worktree
which allows multiple work trees to co-exist. Different work trees must have different branches checked out and can be used for quickly jumping between Salt versions without having to git stash
or git commit
first.
For example, one might have two long living work trees, one that has upstream
's master branch checked out and one for opensuse
's default branch:
# tree -L 1 ~/src/salt
├── openSUSE-3000
└── master
Our Salt packages are done in the "SUSE traditional way", where patch files are inside the RPM source package. It is not possible to generate a tarball from this repository, because the package must provide an original .tar.gz
source tarball and apply patches on top of it.
Since the diff
between the upstream
tarball and in our opensuse
repository can be quite large, we maintain a separate repository with generated .patch
files. These are generated manually with the help of git-format-pkg-patch.
An overview of the Salt Packaging workflow can be seen in the diagram below.
There are two main code streams that we need to handle:
- Latest & greatest Salt for openSUSE Tumbleweed
- Tested & stable Salt for openSUSE Leap and SUSE Linux Enterprise
Each of them have an ever-growing number of OBS projects:
- "production": This version is shipped in the distributions -- bug reports welcome!
- For Tumbleweed: systemsmanagement:saltstack
- For Leap: systemsmanagement:saltstack:products
- "testing": This version is being tested and will move to "production" once all tests pass
- For Tumbleweed: systemsmanagement:saltstack:testing
- For Leap: systemsmanagement:saltstack:products:testing
- "next": This version is a testbed. It might move to "production" (via "testing") or be replaced.
- For Tumbleweed: systemsmanagement:saltstack:next
- For Leap: systemsmanagement:saltstack:products:next
- "next testing": This version is for testing before it moves to "next".
- For Tumbleweed: systemsmanagement:saltstack:next:testing
- For Leap: systemsmanagement:saltstack:products:next:testing
Since there are so many projects and it is easy to forget which Salt version is being built in each project, we have a small tool that queries OBS: saltversions
We have a tool for running upstream
integration and unit tests in Docker containers called Salt Toaster. Salt Toaster also powers an integration test suite from SUSE.
- py-spy: Profiling Python applications