GitHub
Prodvana integrates with GitHub to enrich your deployment experience and associate production changes back to your commits.
How it Works
Prodvana integrates with GitHub via a GitHub Application. Open Container labels are added to your Docker image metadata as labels. These labels are used to link the Docker image to the commit hash.
Setting up GitHub Integration
- Navigate to ORG.runprodvana.com
- Click on "Integrations".
- Click "Connect" under GitHub. This will ask you for your GitHub organization name that you want to connect (this is the part of your repo url after github.com, e.g. github.com/$org/$repo). It does not have to be a public organization.
- The UI will navigate you to GitHub's website to create a new app and give it the right permission to the repos you want to use for deploying.
- You will then be navigated back to Prodvana. Your GitHub is now linked to Prodvana.
Annotating Docker Images with Commit Information
We rely on the following two standard docker labels to figure out which commit your image corresponds to:
Label | Explanation | Example |
---|---|---|
org.opencontainers.image.source | The GitHub repo path, must be prefixed by "github.com". | github.com/nginx/nginx |
org.opencontainers.image.revision | The commit hash | 9b25969173f00f1b62468714105dfc48224eceaf |
If you build your images on CI, you can define these labels there directly and take advantage of builtin variables. For example, for GitHub Actions:
- uses: docker/build-push-action@v2
with:
tags: |
my-registry.com/my-image:latest
my-registry.com/my-image:${{ github.sha }}
labels: |
org.opencontainers.image.revision=${{ github.sha }}
org.opencontainers.image.source=github.com/my-org/my-repo
Enriched UX
With your GitHub integration enabled and your Docker images properly labeled, you can enjoy richer UX from Prodvana.
For example, as part of selecting an image to deploy, you will see the commit hash and message in the UI to give you more context about what you are selecting.
Prodvana also gives a commits view to allow you to easily check if your commit is out and to which Release Channel.
Updated 11 months ago