added weekly build scheduling; removed building on PR, will add seper… #11
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Docker Image CI for GHCR | |
on: | |
push: | |
branches: [ "main" ] | |
schedule: | |
- cron: "59 23 * * 0" | |
jobs: | |
build_and_publish: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@main | |
- name: Build and publish the Docker image to GHCR | |
run: | | |
docker login --username raycadle --password ${{ secrets.GH_PAT }} ghcr.io | |
docker build --build-arg BUILD_DATE="$(date +%d/%m/%y)" --build-arg VERSION="$(date +%R:%S)" --tag ghcr.io/raycadle/ntfy:latest . | |
docker push ghcr.io/raycadle/ntfy:latest |