From f2f92556e7d29a600ae4a84095c40590e01d5c6b Mon Sep 17 00:00:00 2001 From: Cedrik Hoffmann Date: Wed, 24 Jul 2024 21:54:55 +0200 Subject: [PATCH 1/2] feat: add .dockerignore --- .dockerignore | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 .dockerignore diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..4056d41 --- /dev/null +++ b/.dockerignore @@ -0,0 +1,13 @@ +.docker/ +!.docker/nginx.conf +.git/ +.github/ +dist/ +k8s/ +node_modules/ +.dockerignore +.editorconfig +.gitignore +.node-version +CHANGELOG.md +README.md From b7ac50e904c2b9452cd4bf5d02def62de001a990 Mon Sep 17 00:00:00 2001 From: Cedrik Hoffmann Date: Wed, 24 Jul 2024 22:05:06 +0200 Subject: [PATCH 2/2] ci/cd: specify path in github action when to run build --- .github/workflows/build-and-push-develop.yml | 10 ++++++++++ .github/workflows/build-and-push-production.yml | 10 ++++++++++ .github/workflows/build-and-push-stage.yml | 10 ++++++++++ 3 files changed, 30 insertions(+) diff --git a/.github/workflows/build-and-push-develop.yml b/.github/workflows/build-and-push-develop.yml index 7a29167..343ab68 100644 --- a/.github/workflows/build-and-push-develop.yml +++ b/.github/workflows/build-and-push-develop.yml @@ -1,6 +1,16 @@ name: Build and Push Docker Image Develop "on": push: + paths: + - "**/**" + - "!.github/**" + - "!k8s/**" + - "!.dockerignore" + - "!.editorconfig" + - "!.gitignore" + - "!.node-version" + - "!CHANGELOG.md" + - "!README.md" branches: - develop diff --git a/.github/workflows/build-and-push-production.yml b/.github/workflows/build-and-push-production.yml index d8ab2b9..18f7eed 100644 --- a/.github/workflows/build-and-push-production.yml +++ b/.github/workflows/build-and-push-production.yml @@ -2,6 +2,16 @@ name: Build and Push Docker Image Production on: pull_request: + paths: + - "**/**" + - "!.github/**" + - "!k8s/**" + - "!.dockerignore" + - "!.editorconfig" + - "!.gitignore" + - "!.node-version" + - "!CHANGELOG.md" + - "!README.md" branches: - main types: diff --git a/.github/workflows/build-and-push-stage.yml b/.github/workflows/build-and-push-stage.yml index c8b6623..09b8535 100644 --- a/.github/workflows/build-and-push-stage.yml +++ b/.github/workflows/build-and-push-stage.yml @@ -2,6 +2,16 @@ name: Build and Push Docker Image Staging "on": workflow_dispatch: push: + paths: + - "**/**" + - "!.github/**" + - "!k8s/**" + - "!.dockerignore" + - "!.editorconfig" + - "!.gitignore" + - "!.node-version" + - "!CHANGELOG.md" + - "!README.md" branches: - release/* - hotfix/*