The release workflow requires the following secrets to be configured in your GitHub repository:
- Go to GitHub repository → Settings → Secrets and variables → Actions
- Add the following secrets:
- QUAY_USERNAME: Your Quay.io username (e.g.,
mathianasj) - QUAY_TOKEN: Your Quay.io Robot Account token or password
- Go to https://quay.io/repository/mathianasj/virt-git-sync
- Click on the repository (create it if it doesn't exist)
- Go to "Settings" → "Robot Accounts"
- Create a new robot account with "Write" permissions
- Copy the token and add it as
QUAY_TOKENin GitHub secrets
Alternatively, you can use your Quay.io password directly, but a robot account is more secure.
# Make sure all changes are committed and pushed
git status
git push origin master# Create a new version tag (use semantic versioning)
git tag v1.0.0
# Push the tag to GitHub
git push origin v1.0.0Once you push a tag matching v*.*.*, GitHub Actions will automatically:
- ✅ Run all tests
- ✅ Run linting checks
- ✅ Build multi-arch Docker image (linux/amd64 + linux/arm64)
- ✅ Push operator image to
quay.io/mathianasj/virt-git-sync:v1.0.0and:latest - ✅ Build and push OLM bundle to
quay.io/mathianasj/virt-git-sync-bundle:v1.0.0 - ✅ Build and push OLM catalog to
quay.io/mathianasj/virt-git-sync-catalog:v1.0.0 - ✅ Generate installation manifests
- ✅ Create GitHub Release with:
- Auto-generated release notes
- OLM installation instructions
- kubectl installation instructions
- Complete install.yaml manifest
- CRD manifests
- Check GitHub Actions: https://github.com/mathianasj/virt-git-sync/actions
- Check GitHub Releases: https://github.com/mathianasj/virt-git-sync/releases
- Check Quay.io images:
Follow semantic versioning (semver):
- MAJOR.MINOR.PATCH (e.g.,
v1.2.3) - MAJOR: Breaking changes, API incompatibilities
- MINOR: New features, backward-compatible
- PATCH: Bug fixes, backward-compatible
Examples:
v1.0.0- Initial releasev1.1.0- Added new feature (auto-pause)v1.1.1- Bug fix in auto-pausev2.0.0- Breaking change (removed local-only mode)
For alpha/beta releases, use tags like:
git tag v1.0.0-alpha.1
git tag v1.0.0-beta.1
git tag v1.0.0-rc.1The workflow will create the release but mark it as a pre-release automatically.
Install via operator-sdk:
operator-sdk run bundle quay.io/mathianasj/virt-git-sync-bundle:v1.0.0Or create a CatalogSource:
apiVersion: operators.coreos.com/v1alpha1
kind: CatalogSource
metadata:
name: virt-git-sync-catalog
namespace: openshift-marketplace
spec:
sourceType: grpc
image: quay.io/mathianasj/virt-git-sync-catalog:v1.0.0
displayName: VirtGitSync Catalog
publisher: Joshua Mathianas
updateStrategy:
registryPoll:
interval: 15mThen install from OperatorHub UI or create a Subscription:
apiVersion: operators.coreos.com/v1alpha1
kind: Subscription
metadata:
name: virt-git-sync
namespace: openshift-operators
spec:
channel: alpha
name: virt-git-sync
source: virt-git-sync-catalog
sourceNamespace: openshift-marketplacekubectl apply -f https://github.com/mathianasj/virt-git-sync/releases/download/v1.0.0/install.yamlIf the automated workflow fails, you can manually build and push:
# Build and push operator image
export VERSION=1.0.0
export IMG=quay.io/mathianasj/virt-git-sync:v$VERSION
docker login quay.io
make docker-build docker-push IMG=$IMG
# Generate and push OLM bundle
make bundle VERSION=$VERSION IMG=$IMG
make bundle-build bundle-push VERSION=$VERSION
# Generate and push OLM catalog
make catalog-build catalog-push VERSION=$VERSION
# Generate manifests
make build-installer IMG=$IMG
# Create GitHub release manually and upload dist/install.yaml- Verify
QUAY_USERNAMEandQUAY_TOKENsecrets are set correctly - Verify the robot account has "Write" permissions
- Check if the repository exists on Quay.io and is not set to private
- Check the Dockerfile exists and is valid
- Check Go version in workflow matches go.mod
- Review build logs in GitHub Actions
- Run tests locally first:
make test - Check test logs in GitHub Actions
- Fix issues and create a new tag
- Check CSV is valid:
operator-sdk bundle validate ./bundle - Verify all required fields are set (minKubeVersion, etc.)
- Check CRD manifests are up to date:
make manifests