Skip to content

Commit 9f90d1f

Browse files
Merge pull request #10 from artificialio/cd/2025-09-01-manual-job
Make a manual job
2 parents 293b3db + 0e3fb29 commit 9f90d1f

1 file changed

Lines changed: 8 additions & 11 deletions

File tree

.github/workflows/push.yml

Lines changed: 8 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,33 @@
11
name: Push Docker Image
2-
32
on:
4-
push:
5-
tags:
6-
- '*'
3+
workflow_dispatch:
4+
inputs:
5+
release_name:
6+
description: 'Release name/tag for the Docker image'
7+
required: true
8+
type: string
79

810
jobs:
911
docker:
1012
runs-on: ubuntu-latest
1113
permissions:
1214
contents: read
1315
packages: write
14-
1516
steps:
1617
- uses: actions/checkout@v4
17-
1818
- uses: nixbuild/nix-quick-install-action@v28
1919
with:
2020
nix_conf: experimental-features = nix-command flakes
21-
2221
# Log in to GHCR
2322
- name: Log in to GHCR
2423
uses: docker/login-action@v3
2524
with:
2625
registry: ghcr.io
2726
username: ${{ github.actor }}
2827
password: ${{ secrets.GITHUB_TOKEN }}
29-
3028
# Create a docker image
3129
- run: nix run .#packages.x86_64-linux.container.copyToDockerDaemon
32-
- run: docker tag perfly:latest ghcr.io/artificialio/perfly:${{ github.event.release.tag_name }}
33-
30+
- run: docker tag perfly:latest ghcr.io/artificialio/perfly:${{ inputs.release_name }}
3431
# Build and push the image
3532
- name: Build and Push Docker image
3633
uses: docker/build-push-action@v6
@@ -39,4 +36,4 @@ jobs:
3936
push: true
4037
tags: |
4138
ghcr.io/artificialio/perfly:latest
42-
ghcr.io/artificialio/perfly:${{ github.event.release.tag_name }}
39+
ghcr.io/artificialio/perfly:${{ inputs.release_name }}

0 commit comments

Comments
 (0)