-
Notifications
You must be signed in to change notification settings - Fork 102
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feature: add pipeline for publish docker image
Signed-off-by: Javier Criado Marcos <[email protected]>
- Loading branch information
Showing
2 changed files
with
33 additions
and
20 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,10 @@ | ||
name: build-workflow | ||
# This workflow is triggered on pushes to the repository. | ||
on: [push, pull_request] | ||
on: | ||
push: | ||
branches: | ||
- "*" | ||
pull_request: | ||
|
||
jobs: | ||
build: | ||
|
@@ -33,22 +37,3 @@ jobs: | |
run: | | ||
cd charts | ||
PATH=$PATH:/tmp/bin helm upgrade --install --set image.tag=v$GITHUB_SHA_SHORT --set rbac.create=true --wait --timeout 60s log-router ./log-router | ||
publish: | ||
name: publish-job | ||
if: startsWith(github.ref, 'refs/heads/release') | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: FranzDiebold/[email protected] | ||
- name: docker-login | ||
run: | | ||
cd config-reloader && make docker-login | ||
env: # Or as an environment variable | ||
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }} | ||
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }} | ||
- name: build-base | ||
run: | | ||
cd base-image && make build-image | ||
- name: push-image | ||
run: | | ||
cd config-reloader && make push-image |
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,28 @@ | ||
name: build-workflow | ||
# This workflow is triggered on pushes to the repository. | ||
on: | ||
push: | ||
tags: | ||
- '*' | ||
|
||
jobs: | ||
publish: | ||
name: publish-job | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: FranzDiebold/[email protected] | ||
- name: docker-login | ||
run: | | ||
cd config-reloader && make docker-login | ||
env: # Or as an environment variable | ||
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }} | ||
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }} | ||
- name: build-base | ||
run: | | ||
cd base-image && make build-image | ||
- name: push-image | ||
run: | | ||
cd config-reloader && make push-image | ||
env: | ||
TAG: ${{github.ref_name}} |