ci: add container publishing workflow
This commit is contained in:
22
.github/workflows/publish.yaml
vendored
Normal file
22
.github/workflows/publish.yaml
vendored
Normal file
@@ -0,0 +1,22 @@
|
||||
name: Publish container
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
workflow_dispatch:
|
||||
jobs:
|
||||
publish:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- name: Login to Docker Hub
|
||||
uses: docker/login-action@v1
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_HUB_TOKEN }}
|
||||
password: ${{ secrets.DOCKER_HUB_TOKEN }}
|
||||
- name: Set up QEMU
|
||||
uses: docker/setup-qemu-action@v1
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v1
|
||||
- name: Publish container to Docker Hub
|
||||
run: docker buildx build --platform linux/amd64,linux/arm64,linux/arm/v7,linux/arm/v6 --tag "mtoohey/standardnotes-extensions:$(git log -1 --format="%H" | cut -c -6)" --tag mtoohey/standardnotes-extensions:latest --push .
|
||||
@@ -3,6 +3,6 @@ FROM python:3-alpine
|
||||
WORKDIR /build
|
||||
COPY requirements.txt build_repo.py ./
|
||||
|
||||
RUN pip3 install -r requirements.txt
|
||||
RUN pip3 install --no-cache-dir -r requirements.txt
|
||||
|
||||
ENTRYPOINT python3 build_repo.py
|
||||
ENTRYPOINT ["python3", "build_repo.py"]
|
||||
|
||||
Reference in New Issue
Block a user