2 changed files with 36 additions and 0 deletions
@ -0,0 +1,17 @@
@@ -0,0 +1,17 @@
|
||||
name: Build nightly docker |
||||
|
||||
on: |
||||
schedule: |
||||
- cron: "0 0 * * *" |
||||
|
||||
jobs: |
||||
Docker: |
||||
runs-on: ubuntu-latest |
||||
steps: |
||||
|
||||
- name: Log into GitHub Container Registry |
||||
run: echo "${{ secrets.GH_CR_PAT }}" | docker login https://ghcr.io -u ${{ github.actor }} --password-stdin |
||||
|
||||
- uses: actions/checkout@v2 |
||||
- name: Setup and run |
||||
run: cd build/release && ./docker-nightly.sh |
@ -0,0 +1,19 @@
@@ -0,0 +1,19 @@
|
||||
# Docker build |
||||
# Must authenticate first: https://docs.github.com/en/packages/using-github-packages-with-your-projects-ecosystem/configuring-docker-for-use-with-github-packages#authenticating-to-github-packages |
||||
DOCKER_IMAGE="owncast" |
||||
VERSION="nightly" |
||||
GIT_COMMIT=$(git rev-list -1 HEAD) |
||||
|
||||
echo "Building Docker image ${DOCKER_IMAGE}..." |
||||
|
||||
# Change to the root directory of the repository |
||||
cd $(git rev-parse --show-toplevel) |
||||
|
||||
# Docker build |
||||
docker build --build-arg NAME=docker --build-arg VERSION=${VERSION} --build-arg GIT_COMMIT=$GIT_COMMIT -t ghcr.io/owncast/${DOCKER_IMAGE}:nightly . -f build/release/Dockerfile-build |
||||
|
||||
# Dockerhub |
||||
# You must be authenticated via `docker login` with your Dockerhub credentials first. |
||||
# docker push gabekangas/owncast:nightly |
||||
|
||||
docker push ghcr.io/owncast/${DOCKER_IMAGE}:nightly |
Loading…
Reference in new issue