Skip to content

Commit

Permalink
WIP: Add GitHub workflow to build Docker image
Browse files Browse the repository at this point in the history
  • Loading branch information
JeremyMcCormick committed Sep 20, 2024
1 parent e68c062 commit 81ca547
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 1 deletion.
31 changes: 31 additions & 0 deletions .github/workflows/docker.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Docker
on:
pull_request: {}
push:
tags:
- "*"

jobs:
docker:
runs-on: ubuntu-latest
timeout-minutes: 10
permissions:
contents: read
packages: write

steps:
- uses: actions/checkout@v4
with:
# Needed to fetch tags, used by Python install process to
# figure out version number
fetch-depth: 0

- uses: lsst-sqre/build-and-push-to-ghcr@v1
id: build
with:
image: "lsst/apdb-ppdb-replication"
dockerfile: "docker/Dockerfile.replication"
github_token: ${{ secrets.GITHUB_TOKEN }}
push: false

- run: echo Pushed ghcr.io/${{ github.repository }}:${{ steps.build.outputs.tag }}
1 change: 0 additions & 1 deletion docker/Dockerfile.replication
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ RUN apt-get -y install --no-install-recommends git
RUN apt-get clean
RUN rm -rf /var/lib/apt/lists/*

RUN pip install --no-cache-dir .
RUN pip install --no-cache-dir --upgrade pip
RUN pip install --no-cache-dir wheel
RUN pip install --no-cache-dir -r requirements.txt
Expand Down

0 comments on commit 81ca547

Please sign in to comment.