Skip to content

Commit

Permalink
workflow for building docker
Browse files Browse the repository at this point in the history
  • Loading branch information
ulfgebhardt committed Feb 26, 2024
1 parent d771eeb commit 82ae9f4
Show file tree
Hide file tree
Showing 2 changed files with 49 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .github/file-filters.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ frontend-test-unit-code: &frontend-test-unit-code
frontend-test-build-code: &frontend-test-build-code
- '**/*'

frontend-test-build-docker: &frontend-test-build-docker
- '**/*'

frontend-test-build-docs: &frontend-test-build-docs
- '**/*.md'
- '.vuepress/*'
Expand Down
46 changes: 46 additions & 0 deletions .github/workflows/frontend.test.build.docker.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: "frontend:test:build test docker"

on: push

jobs:
# only (but most important) job from this workflow required for pull requests
# check results serve as run conditions for all other jobs here
files-changed:
name: Detect File Changes - frontend-test-build-docker
runs-on: ubuntu-latest
outputs:
changes: ${{ steps.changes.outputs.frontend-test-build-docker }}
steps:
- uses: actions/checkout@v4

- name: Check for frontend file changes
uses: dorny/paths-filter@v3.0.1
id: changes
with:
token: ${{ github.token }}
filters: .github/file-filters.yml
list-files: shell

build-production:
if: needs.files-changed.outputs.changes == 'true'
name: Build Docker Production - Frontend
needs: files-changed
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Frontend | Build Docker Production
run: docker compose -f docker-compose.yml build

build-development:
if: needs.files-changed.outputs.changes == 'true'
name: Build Docker Development - Frontend
needs: files-changed
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Frontend | Build Docker Development
run: docker compose build

0 comments on commit 82ae9f4

Please sign in to comment.