Skip to content

Commit

Permalink
Merge pull request #3 from BrandwatchLtd/CCTQ-159
Browse files Browse the repository at this point in the history
publish docker image to docker.artifactory
  • Loading branch information
jaydanielsencision authored Oct 15, 2024
2 parents b44b573 + 70a0f67 commit 9855927
Showing 1 changed file with 17 additions and 12 deletions.
29 changes: 17 additions & 12 deletions .github/workflows/build-deploy-pipeline.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,18 +42,23 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.TOKEN }}

- name: Build image
uses: Brandwatch/bw-workflow-actions/steps/generic/dockerfile-image@production
docker:
runs-on: ubuntu-latest
steps:
- name: Log in to docker.artifactory.brandwatch.com
uses: docker/login-action@v3
with:
images: ${{ github.event.repository.name }}
tag: ${{ github.ref_name }}-${{ github.run_id }}
brandwatch-artifactory-docker-push-password: ${{ secrets.ARTIFACTORY_DOCKER_PUSH_PASSWORD }}
cpu-architectures: amd64
registry: docker.artifactory.brandwatch.com
username: github-actions-docker-push
password: ${{ secrets.ARTIFACTORY_DOCKER_PUSH_PASSWORD }}

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Scan And Push Image
uses: Brandwatch/bw-workflow-actions/steps/generic/scan-and-push-image@production
- name: Build and push
uses: docker/build-push-action@v6
with:
artifactory-pwd: ${{ secrets.ARTIFACTORY_DOCKER_PUSH_PASSWORD }}
images: ${{ github.event.repository.name }}
tag: ${{ github.ref_name }}-${{ github.run_id }}
trivy-kill-key: ${{ secrets.TRIVY_KILL_KEY }}
push: true
tags: |
${{ format('{0}/{1}-{2}', github.event.repository.name, github.ref_name, 'amd64') }}
${{ format('{0}/{1}-{2}', github.event.repository.name, github.ref_name, github.run_id) }}

0 comments on commit 9855927

Please sign in to comment.