Skip to content

Commit

Permalink
Some changes in gihub actions and Dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
slaveeks committed Apr 21, 2022
1 parent 432e6b9 commit 6df020e
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
13 changes: 11 additions & 2 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ on:

env:
DOCKER_REPO: codex-team/opencollective-webhook
IMAGE_NAME: ${{ github.repository }}
REGISTRY: ghcr.io

jobs:
lint:
Expand All @@ -27,13 +29,20 @@ jobs:
- name: Login to GitHub Container Registry
uses: docker/login-action@v1
with:
registry: ghcr.io
registry: env.REGISTRY
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@v3
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}

- name: Build and push production image
uses: docker/build-push-action@v2
with:
context: .
push: ${{ endsWith(github.ref, 'refs/tags/v') }}
tags: ${{ steps.meta.outputs.tags }}
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
2 changes: 0 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,4 @@ WORKDIR /

COPY --from=build /opencollective-webhook /opencollective-webhook

COPY .env ./

ENTRYPOINT ["/opencollective-webhook"]

0 comments on commit 6df020e

Please sign in to comment.