diff options
author | André Oliveira <37463445+SpecialAro@users.noreply.github.com> | 2022-06-08 11:59:11 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-06-08 11:59:11 +0100 |
commit | 2c26341d37f36e5431ad6c4eb0ee690bf0cfe151 (patch) | |
tree | 918a282800306d881db632abfa48f8d787de177b | |
parent | Test on docker meta (#39) (diff) | |
download | ferdium-server-2c26341d37f36e5431ad6c4eb0ee690bf0cfe151.tar.gz ferdium-server-2c26341d37f36e5431ad6c4eb0ee690bf0cfe151.tar.zst ferdium-server-2c26341d37f36e5431ad6c4eb0ee690bf0cfe151.zip |
Fix build - should_run not properly set (#40)
-rw-r--r-- | .github/workflows/docker.yml | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index c07cd2a..775706e 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml | |||
@@ -21,7 +21,6 @@ jobs: | |||
21 | - | 21 | - |
22 | name: Check whether there are any commits since this run was last triggered and push them and/or set the output | 22 | name: Check whether there are any commits since this run was last triggered and push them and/or set the output |
23 | id: should_run | 23 | id: should_run |
24 | if: ${{ (github.event_name == 'workflow_dispatch' && contains(github.event.inputs.message, '[main]')) }} | ||
25 | run: | | 24 | run: | |
26 | git config user.name github-actions | 25 | git config user.name github-actions |
27 | git config user.email github-actions@github.com | 26 | git config user.email github-actions@github.com |
@@ -63,6 +62,7 @@ jobs: | |||
63 | - | 62 | - |
64 | name: Docker meta | 63 | name: Docker meta |
65 | id: meta | 64 | id: meta |
65 | if: ${{ (steps.should_run.outputs.should_run != 'false') && (github.event_name != 'workflow_dispatch' || (github.event_name == 'workflow_dispatch' && (contains(github.event.inputs.message, '[main]'))) )}} | ||
66 | uses: docker/metadata-action@v4 | 66 | uses: docker/metadata-action@v4 |
67 | with: | 67 | with: |
68 | # list of Docker images to use as base name for tags | 68 | # list of Docker images to use as base name for tags |
@@ -76,12 +76,15 @@ jobs: | |||
76 | - | 76 | - |
77 | name: Set up QEMU | 77 | name: Set up QEMU |
78 | uses: docker/setup-qemu-action@v2 | 78 | uses: docker/setup-qemu-action@v2 |
79 | if: ${{ (steps.should_run.outputs.should_run != 'false') && (github.event_name != 'workflow_dispatch' || (github.event_name == 'workflow_dispatch' && (contains(github.event.inputs.message, '[main]'))) )}} | ||
79 | - | 80 | - |
80 | name: Set up Docker Buildx | 81 | name: Set up Docker Buildx |
81 | uses: docker/setup-buildx-action@v2 | 82 | uses: docker/setup-buildx-action@v2 |
83 | if: ${{ (steps.should_run.outputs.should_run != 'false') && (github.event_name != 'workflow_dispatch' || (github.event_name == 'workflow_dispatch' && (contains(github.event.inputs.message, '[main]'))) )}} | ||
82 | - | 84 | - |
83 | name: Login to GitHub Container Registry | 85 | name: Login to GitHub Container Registry |
84 | uses: docker/login-action@v2 | 86 | uses: docker/login-action@v2 |
87 | if: ${{ (steps.should_run.outputs.should_run != 'false') && (github.event_name != 'workflow_dispatch' || (github.event_name == 'workflow_dispatch' && (contains(github.event.inputs.message, '[main]'))) )}} | ||
85 | with: | 88 | with: |
86 | registry: ghcr.io | 89 | registry: ghcr.io |
87 | username: ${{ github.repository_owner }} | 90 | username: ${{ github.repository_owner }} |
@@ -89,12 +92,13 @@ jobs: | |||
89 | - | 92 | - |
90 | name: Login to DockerHub | 93 | name: Login to DockerHub |
91 | uses: docker/login-action@v2 | 94 | uses: docker/login-action@v2 |
95 | if: ${{ (steps.should_run.outputs.should_run != 'false') && (github.event_name != 'workflow_dispatch' || (github.event_name == 'workflow_dispatch' && (contains(github.event.inputs.message, '[main]'))) )}} | ||
92 | with: | 96 | with: |
93 | username: ${{ secrets.DOCKERHUB_USERNAME }} | 97 | username: ${{ secrets.DOCKERHUB_USERNAME }} |
94 | password: ${{ secrets.DOCKERHUB_TOKEN }} | 98 | password: ${{ secrets.DOCKERHUB_TOKEN }} |
95 | - | 99 | - |
96 | name: Build and push | 100 | name: Build and push |
97 | if: ${{ (github.event_name == 'workflow_dispatch' && contains(github.event.inputs.message, '[main]')) }} | 101 | if: ${{ (steps.should_run.outputs.should_run != 'false') && (github.event_name != 'workflow_dispatch' || (github.event_name == 'workflow_dispatch' && (contains(github.event.inputs.message, '[main]'))) )}} |
98 | uses: docker/build-push-action@v3 | 102 | uses: docker/build-push-action@v3 |
99 | with: | 103 | with: |
100 | context: . | 104 | context: . |