diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index d3330a2..124b79a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,14 +1,16 @@ --- name: 'build go project' -on: [push] +on: + workflow_dispatch: + push: jobs: build: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@main - name: Set up Go uses: actions/setup-go@v4 diff --git a/.github/workflows/containers.yml b/.github/workflows/containers.yml index 4749eee..d9129d9 100644 --- a/.github/workflows/containers.yml +++ b/.github/workflows/containers.yml @@ -2,21 +2,24 @@ name: 'build images' on: - push: - tags: - - '*' + workflow_dispatch: + inputs: + version: + description: "version" + required: false + type: string jobs: docker: runs-on: ubuntu-latest steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@main - name: Prepare id: prep run: | DOCKER_IMAGE=${{ secrets.DOCKER_USERNAME }}/${GITHUB_REPOSITORY#*/} - VERSION=${GITHUB_REF/refs\/tags\//} + VERSION=${{ inputs.version }} SHORTREF=${GITHUB_SHA::8} TAGS="${DOCKER_IMAGE}:${VERSION},${DOCKER_IMAGE}:latest"