mirror of
https://github.com/oskvr37/tiddl.git
synced 2026-06-13 04:05:08 +03:00
🐬 Added Docker stuff (#138)
* Docker flow * (Commit so my commit is verified) --------- Co-authored-by: Xiliourt <admin@xiliourt.ovh>
This commit is contained in:
@@ -0,0 +1,39 @@
|
||||
name: Push Docker Image to ghcr.io
|
||||
|
||||
# Run when release is published
|
||||
on:
|
||||
release:
|
||||
types: [published]
|
||||
workflow_dispatch: # Allow for manual push so I can test it
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
# Minimum required permissions
|
||||
permissions:
|
||||
contents: read
|
||||
packages: write
|
||||
|
||||
steps:
|
||||
# Checkout code
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v3
|
||||
|
||||
# Login to ghcr (automatically uses workflow actor and secret)
|
||||
- name: Login to GitHub Container Registry
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: ghcr.io
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
# Pushes to both :latest and :<versionTag>
|
||||
- name: Build and push
|
||||
uses: docker/build-push-action@v6
|
||||
with:
|
||||
context: .
|
||||
push: true
|
||||
tags: |
|
||||
ghcr.io/${{ github.repository_owner }}/tiddl:${{ github.event.release.tag_name }}
|
||||
ghcr.io/${{ github.repository_owner }}/tiddl:latest
|
||||
Reference in New Issue
Block a user