2024-11-28 10:04:46 +02:00
|
|
|
name: Build and Push Docker Image
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
2024-12-07 16:10:07 +02:00
|
|
|
- main
|
2024-11-28 10:04:46 +02:00
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
name: Build and Push Image
|
2024-12-07 16:10:07 +02:00
|
|
|
runs-on: ubuntu-latest-root
|
2024-11-28 10:04:46 +02:00
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: Checkout Repository
|
|
|
|
uses: actions/checkout@v4
|
|
|
|
|
|
|
|
- name: Login to Docker Registry
|
|
|
|
uses: docker/login-action@v3
|
|
|
|
with:
|
2024-12-07 16:10:07 +02:00
|
|
|
registry: git.vavakado.xyz
|
|
|
|
username: vavakado
|
|
|
|
password: ${{ secrets.REGISTRY_TOKEN }}
|
2024-11-28 10:04:46 +02:00
|
|
|
|
|
|
|
- name: Build Docker Image
|
|
|
|
run: |
|
|
|
|
TODAY=$(date +'%Y-%m-%d')
|
2024-11-29 23:20:51 +02:00
|
|
|
docker build -t git.vavakado.xyz/vavakado/exmr:${TODAY} .
|
|
|
|
docker tag git.vavakado.xyz/vavakado/exmr:${TODAY} git.vavakado.xyz/vavakado/exmr:latest
|
2024-11-28 10:04:46 +02:00
|
|
|
|
|
|
|
- name: Push Docker Image
|
|
|
|
run: |
|
|
|
|
TODAY=$(date +'%Y-%m-%d')
|
2024-11-29 23:20:51 +02:00
|
|
|
docker push git.vavakado.xyz/vavakado/exmr:${TODAY}
|
|
|
|
docker push git.vavakado.xyz/vavakado/exmr:latest
|