forked from VirtusLab/jenkins-operator
-
Notifications
You must be signed in to change notification settings - Fork 236
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(backup): add backup img ci for e2e tests, docker build and push (#…
…795) also fix the current CI
- Loading branch information
1 parent
e9fbe57
commit d91a729
Showing
5 changed files
with
78 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
name: Release Backup Pvc | ||
on: | ||
workflow_dispatch: | ||
pull_request: | ||
types: [edited, opened, reopened, synchronize] | ||
paths: | ||
- 'backup/pvc/**' | ||
|
||
push: | ||
branches: ["master"] | ||
tags: ["*"] | ||
paths: | ||
- 'backup/pvc/**' | ||
|
||
jobs: | ||
build-and-release-backup: | ||
name: Release Backup Pvc, build, bump and push new image | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v2 | ||
|
||
- name: Build the e2e image | ||
run: make -C backup/pvc docker-build-e2e | ||
|
||
- name: Run the e2e tests | ||
run: make -C backup/pvc docker-e2e | ||
|
||
- name: Configure Git | ||
if: github.ref == 'refs/heads/master' && github.event_name != 'pull_request' | ||
run: | | ||
git config user.name "$GITHUB_ACTOR" | ||
git config user.email "[email protected]" | ||
- name: Bump the version | ||
if: github.ref == 'refs/heads/master' && github.event_name != 'pull_request' | ||
run: make -C backup/pvc sembump && make -C backup/pvc bump-version | ||
|
||
- name: Login to Quay.io | ||
if: github.ref == 'refs/heads/master' && github.event_name != 'pull_request' | ||
uses: docker/login-action@v1 | ||
with: | ||
registry: quay.io | ||
username: ${{ secrets.QUAYIO_USERNAME }} | ||
password: ${{ secrets.QUAYIO_TOKEN }} | ||
|
||
- name: Build and push the image to DockerHub | ||
if: github.ref == 'refs/heads/master' && github.event_name != 'pull_request' | ||
run: | | ||
git reset --hard | ||
make -C backup/pvc docker-build | ||
make -C backup/pvc docker-release |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
# Setup variables for the Makefile | ||
NAME=pvc | ||
QUAY_ORGANIZATION=jenkins-kubernetes-operator | ||
QUAY_REGISTRY=backup-pvc | ||
QUAY_REGISTRY=backup | ||
UID=1000 | ||
GID=1000 |