packit / hardly

Project is archived since Packit team agreed on prioritising work with more benefits and bigger user base.
https://packit.dev/source-git/status
MIT License
0 stars 7 forks source link

Hardly

Build Status black pre-commit

Code for (Celery) worker used in our "Stream service". It reuses packit-service's worker code and implements new jobs as new handlers.

Workflow

The service is similar to Packit service, but is expected to eventually follow this workflow:

Must have:
Should have:
Could have:

Running it locally

Similar to packit-service we have a docker-compose.yml for fast prototyping.

It expects, that you have:

Follow the packit-service's guide for the other settings. Once you have it running (and see no errors), you can test (uses HTTPie) the webhook with:

cat tests/data/webhooks/gitlab/mr_event.json | http --verify=no https://service.localhost:8443/api/webhooks/gitlab

How to deploy

To deploy the service into Openshift cluster, clone the deployment repo and:

  1. create the variable files in vars/stream/
  2. link secrets into secrets / stream/{prod|stg}
  3. SERVICE={fedora-source-git|stream} DEPLOYMENT={deployment} make deploy

Image

The image is currently based on the packit-worker image but that might change in the future to decouple those.

For running locally with docker-compose, build it with docker-compose build.

For deploying in cluster, the image is built and pushed to Quay.io whenever you push to main. Or you can rebuild manually in Actions.

Actual deployments

Tests

Locally: make test-image && make check-in-container

CI: Zuul