Skip to content

Symfony Flex Server #68

Symfony Flex Server

Symfony Flex Server #68

name: Symfony Flex Server
on:
push:
branches: [ master ]
paths:
- 'symfony-flex-server/**'
- '.github/workflows/symfony-flex-server.yaml'
pull_request:
paths:
- 'symfony-flex-server/**'
- '.github/workflows/symfony-flex-server.yaml'
schedule:
- cron: '0 0 1,15 * *'
workflow_dispatch:
jobs:
build:
name: latest
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Authenticate to Github Docker Packages
run: echo ${{ github.token }} | docker login ghcr.io -u ${{ github.actor }} --password-stdin
- name: Build image
run: cd symfony-flex-server && docker build -t ghcr.io/${{ github.repository }}/symfony-flex-server:latest .
- name: List images
run: docker images
- name: Publish image
if: (github.event_name == 'push' || github.event_name == 'schedule' || github.event_name == 'workflow_dispatch') && github.ref == 'refs/heads/master'
run: docker push ghcr.io/${{ github.repository }}/symfony-flex-server:latest