Skip to content

Commit

Permalink
1.0.50 Add variables to the github action
Browse files Browse the repository at this point in the history
  • Loading branch information
webpwnized committed Oct 16, 2023
1 parent 4fbb1c7 commit 2dff7a1
Showing 1 changed file with 11 additions and 5 deletions.
16 changes: 11 additions & 5 deletions .github/workflows/build-and-push-to-dockerhub.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ jobs:
docker:
runs-on: ubuntu-latest
steps:
# --------------------------------------
# Prepare the runner
# --------------------------------------
-
name: Check out the codebase
uses: actions/checkout@v4
Expand All @@ -41,8 +44,11 @@ jobs:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

# ----------------------------------------------------------------------------
# Database Container
# ----------------------------------------------------------------------------
-
name: Build and Export ${{ env.DATABASE_CONTAINER_NAME }} Container to Docker
name: Build and Export Database Container to Docker
uses: docker/build-push-action@v5
with:
context: .
Expand All @@ -51,21 +57,21 @@ jobs:
tags: webpwnized/mutillidae:${{ env.DATABASE_CONTAINER_NAME }}

-
name: Run Trivy vulnerability scanner on ${{ env.DATABASE_CONTAINER_NAME }} Container
name: Run Trivy vulnerability scanner on Database Container
uses: aquasecurity/trivy-action@master
with:
image-ref: 'webpwnized/mutillidae:${{ env.DATABASE_CONTAINER_NAME }}'
format: 'sarif'
output: '${{ env.DATABASE_CONTAINER_NAME }}-trivy-scan-results.sarif'

-
name: Upload ${{ env.DATABASE_CONTAINER_NAME }} Container Trivy scan results to GitHub Security tab
name: Upload Database Container Trivy scan results to GitHub Security tab
uses: github/codeql-action/upload-sarif@v2
with:
sarif_file: '${{ env.DATABASE_CONTAINER_NAME }}-trivy-scan-results.sarif'

-
name: Build and push ${{ env.DATABASE_CONTAINER_NAME }} container
name: Build and push Database container
uses: docker/build-push-action@v5
with:
context: .
Expand All @@ -74,7 +80,7 @@ jobs:
tags: webpwnized/mutillidae:${{ env.DATABASE_CONTAINER_NAME }}

-
name: Build and push ${{ env.DATABASE_CONTAINER_NAME }} container with version number
name: Build and push Database container with version number
uses: docker/build-push-action@v5
with:
context: .
Expand Down

0 comments on commit 2dff7a1

Please sign in to comment.