35 lines
815 B
YAML
35 lines
815 B
YAML
name: Build Docker image
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
docker:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Login to Registry
|
|
uses: docker/login-action@v3
|
|
with:
|
|
registry: ${{ secrets.REGISTRY_URL }}
|
|
username: ${{ secrets.REGISTRY_USERNAME }}
|
|
password: ${{ secrets.REGISTRY_TOKEN }}
|
|
|
|
- name: Build and push Docker images
|
|
uses: docker/build-push-action@v6
|
|
with:
|
|
push: true
|
|
context: .
|
|
file: docker/php/Dockerfile
|
|
target: prod
|
|
tags: ${{ secrets.REGISTRY_URL }}/goteo-v4:latest
|
|
|
|
- name: Notify Webhook
|
|
run: |
|
|
curl -X POST ${{ secrets.WEBHOOK_URL }} -d 'success'
|