github packages #204
  
    
      This file contains hidden or 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: github packages | |
| on: | |
| # Rebuild the container once every week | |
| schedule: | |
| - cron: '0 0 * * 1' | |
| push: | |
| branches: | |
| - "main" | |
| paths: | |
| - "Dockerfile" | |
| pull_request: | |
| paths: | |
| - "Dockerfile" | |
| workflow_dispatch: | |
| jobs: | |
| docker: | |
| runs-on: ubuntu-20.04 | |
| steps: | |
| - name: Login to GitHub Container Registry | |
| uses: docker/login-action@v3 | |
| with: | |
| username: ${{ github.actor }} | |
| password: ${{ secrets.GITHUB_TOKEN }} | |
| registry: ghcr.io | |
| - name: Push to GitHub Packages | |
| uses: docker/build-push-action@v6 | |
| with: | |
| push: ${{ github.event_name != 'pull_request' }} | |
| tags: ghcr.io/${{ github.repository }}/core:latest |