All the osc commands can be done via the WebUI - but using cli commands makes documentation so much easier ;-).
TIP:
Before you create a rpm package for your service you may want to branch the container,
this create a repo named home:<username>:branches:OBS:Server:Unstable
if it
not already exists.
In this OBS project you can easily create your new package (e.g. obs-service-example
)
and include it later on in your own services container.
You should create a new public git repository (preferable in https://github.com/openSUSE)
Each service contains at least 2 files:
- A executable file which will be executed (e.g. example)
- An option
--outdir
is required
- An option
- A xml service description (
<script_name>.service
)
xmllint --relaxng service.rng example.service
If you create a test package including a _service
to run this service, you can easily
test while development.
git clone https://github.com/openSUSE/open-build-service/
cd open-build-service
kanku up
Choose the image for your preferred virtualization solution at openbuildservice.org and create your own running OBS instance.
3.1 Branch obs-source-service-podman
osc branch OBS:Server:Unstable/obs-source-service-podman
You need to add a <package name="obs-service-example"/>
entry to the kiwi file
- Create a new test package with a
_service
file containing yourexample
service. - Commit it to your test OBS instance
- Run
osc service rr
to trigger the service
The default is to run services without network access. If your new service needs
network access you need to enhance the call-service-in-container
(The line number may change in future, search for WITH_NET="1"
).
To get it into production systems please open an issue (containing a link to the bugzilla audit request) and a pull request in the open-build-service github repository
4. Deployment on https://build.opensuse.org
You can't deploy service on build.opensuse.org by yourself, but you can start a review process by doing the following:
To run your service on https://build.opensuse.org a security audit has to be done by the SUSE security team. You can simply open an audit request on https://bugzilla.opensuse.org.
Once your audit bug gets closed (successfully) you can create a submit request for your new service package and the container to OBS:Server:Unstable