Skip to content

Merge pull request #499 from bcgov-nr/fix/starburst #81

Merge pull request #499 from bcgov-nr/fix/starburst

Merge pull request #499 from bcgov-nr/fix/starburst #81

# Continuous Integration
name: Build and push prod image
on:
workflow_dispatch:
push:
branches:
- main
tags:
- 'v*'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build-push-image:
name: Build and push prod image
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Cache Docker layers
uses: actions/cache@v3
with:
path: /tmp/.buildx-cache
key: ${{ runner.os }}-buildx-${{ github.sha }}
restore-keys: |
${{ runner.os }}-buildx-
- name: Log in to the Container registry
uses: docker/login-action@v2
with:
registry: ${{ secrets.ARTIFACTORY_REGISTRY }}
username: ${{ secrets.ARTIFACTORY_USERNAME }}
password: ${{ secrets.ARTIFACTORY_PASSWORD }}
- name: Build and push image
uses: docker/build-push-action@v3
with:
context: ./
push: true
tags: ${{ secrets.ARTIFACTORY_REGISTRY }}/nr-funbucks:latest
cache-from: type=gha
cache-to: type=gha,mode=max
build-args: |
REPO_LOCATION=