-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2ed0ef7
commit 92de6b3
Showing
2 changed files
with
43 additions
and
1 deletion.
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,42 @@ | ||
name: Docker Image (onpremise-agri-01) | ||
|
||
on: | ||
push: | ||
tags: | ||
- "*" | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
environment: | ||
name: onpremise-agri-01 | ||
|
||
steps: | ||
- name: Checkout Code | ||
uses: actions/[email protected] | ||
|
||
- name: Extract Version from package.json | ||
id: project_version | ||
run: echo "::set-output name=version::$(node -e 'console.log(require("./package.json").version)')" | ||
|
||
- name: Build the Docker Image | ||
run: | | ||
docker build \ | ||
--file Dockerfile \ | ||
--tag robolaunchio/frontend-onpremise:${{ steps.project_version.outputs.version }}-agri-01 \ | ||
--build-arg REACT_APP_BACKEND_URL=${{ secrets.REACT_APP_BACKEND_URL }} \ | ||
--build-arg REACT_APP_KEYCLOAK_URL=${{ secrets.REACT_APP_KEYCLOAK_URL }} \ | ||
--build-arg REACT_APP_KEYCLOAK_REALM=${{ secrets.REACT_APP_KEYCLOAK_REALM }} \ | ||
--build-arg REACT_APP_KEYCLOAK_CLIENT_ID=${{ secrets.REACT_APP_KEYCLOAK_CLIENT_ID }} \ | ||
--build-arg REACT_APP_DEFAULT_MODE=${{ secrets.REACT_APP_DEFAULT_MODE }} \ | ||
--build-arg REACT_APP_SWITCHABLE_MODE=${{ secrets.REACT_APP_SWITCHABLE_MODE }} \ | ||
--build-arg REACT_APP_CREATABLE_ORGANIZATION=${{ secrets.REACT_APP_CREATABLE_ORGANIZATION }} \ | ||
--build-arg REACT_APP_CREATABLE_REGION=${{ secrets.REACT_APP_CREATABLE_REGION }} \ | ||
--build-arg REACT_APP_CREATABLE_INSTANCE=${{ secrets.REACT_APP_CREATABLE_INSTANCE }} \ | ||
. | ||
- name: Login to Docker Hub | ||
run: docker login -u ${{ secrets.DOCKER_USERNAME }} -p ${{ secrets.DOCKER_PASSWORD }} | ||
|
||
- name: Push the Docker Image to Docker Hub | ||
run: docker push robolaunchio/frontend-onpremise:${{ steps.project_version.outputs.version }}-agri-01 |
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