forked from software-mansion-labs/GoL2
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove certificate modification in Dockerfile, add new CI/CD for prod…
…uction This commit removes the certificate modification step in the Dockerfile and adds a new GitHub workflow for production CI/CD. The new workflow involves different steps for Docker meta creation, Google authentication, Docker registry login, and image build & push operations. This is primarily for enhancing automation and managing deployments better.
- Loading branch information
1 parent
9fe0fc6
commit 8df24ed
Showing
3 changed files
with
49 additions
and
5 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 |
---|---|---|
@@ -0,0 +1,47 @@ | ||
name: gol2 | ||
|
||
on: | ||
push: | ||
tags: | ||
- 'v*' | ||
workflow_dispatch: | ||
|
||
jobs: | ||
Build: | ||
runs-on: ubuntu-latest | ||
outputs: | ||
tag: ${{ steps.meta.outputs.version }} | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Docker meta | ||
id: meta | ||
uses: docker/metadata-action@v5 | ||
with: | ||
images: europe-west9-docker.pkg.dev/gol2-development/gol2-indexer/dev | ||
flavor: latest=false | ||
tags: | | ||
type=ref,event=tag | ||
- uses: 'google-github-actions/auth@v2' | ||
id: auth | ||
with: | ||
token_format: access_token | ||
project_id: 'gol2-production' | ||
credentials_json: '${{ secrets.GOOGLE_CREDENTIALS_PROD }}' | ||
|
||
- name: Login to GAR | ||
uses: docker/login-action@v3 | ||
with: | ||
registry: europe-west9-docker.pkg.dev | ||
username: oauth2accesstoken | ||
password: ${{ steps.auth.outputs.access_token }} | ||
|
||
- name: Build and push | ||
uses: docker/build-push-action@v5 | ||
with: | ||
file: Dockerfile | ||
push: true | ||
tags: ${{ steps.meta.outputs.tags }} | ||
labels: ${{ steps.meta.outputs.labels }} |
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