Skip to content

Commit

Permalink
Refactor CI/CD workflows for DemoContainerSecurity and react-app
Browse files Browse the repository at this point in the history
- Updated buildAndPushContainer.yml to include paths for DemoContainerSecurity container
- Updated jhipsterCiCd.yml to include paths for DemoContainerSecurity app
- Updated simpleCiPipeline.yml to include paths for react-app
  • Loading branch information
DoPaNik committed Dec 10, 2023
1 parent 2989983 commit 8cfd271
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 10 deletions.
20 changes: 12 additions & 8 deletions .github/workflows/buildAndPushContainer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,30 +8,34 @@ on:
push:
branches:
- main
paths:
- 2_supplychain/2_praxis/DemoContainerSecurity/Demo/container/**
pull_request:
branches: [ "**" ]

paths:
- 2_supplychain/2_praxis/DemoContainerSecurity/Demo/container/**
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout Repository
- name: Checkout 🛎️
uses: actions/checkout@v4

- name: Docker Setup QEMU
- name: Docker Setup QEMU 🖥️
uses: docker/[email protected]

- name: Docker Setup Buildx
- name: Docker Setup Buildx 🛠️
uses: docker/[email protected]

- name: Login to Docker Hub
- name: Login to Docker Hub 💁‍♀️🐳
uses: docker/[email protected]
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- name: Build and push Docker image
- name: Build and push Docker image 🛠️💾↗️
if: ${{ github.event_name != 'pull_request' }}
uses: docker/[email protected]
with:
Expand All @@ -45,7 +49,7 @@ jobs:
cache-from: type=gha
cache-to: type=gha,mode=max

- name: Build and push Docker image for pull request
- name: Build and push Docker image for pull request 🛠️💾↗️
if: ${{ github.event_name == 'pull_request' }}
uses: docker/[email protected]
with:
Expand All @@ -58,7 +62,7 @@ jobs:
cache-from: type=gha
cache-to: type=gha,mode=max

- name: Docker Scout
- name: Docker Scout 🕵️
id: docker-scout
if: ${{ github.event_name == 'pull_request' }}
uses: docker/scout-action@v1
Expand Down
12 changes: 11 additions & 1 deletion .github/workflows/jhipsterCiCd.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
name: JHipster CI/CD Pipeline
on: [push, pull_request]
on:
push:
branches:
- main
paths:
- 2_supplychain/2_praxis/DemoContainerSecurity/Demo/app/**
pull_request:
branches: [ "**" ]
paths:
- 2_supplychain/2_praxis/DemoContainerSecurity/Demo/app/**
workflow_dispatch:
jobs:
pipeline:
name: app pipeline
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/simpleCiPipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@ on:
push:
branches:
- main
workflow_dispatch:
paths:
- 0_devops/2_praxis/ContinuousIntegration/Demo/react-app/**
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
Expand Down

0 comments on commit 8cfd271

Please sign in to comment.