Skip to content

Docker Image CI

Docker Image CI #793

Workflow file for this run

name: Docker Image CI
on:
push:
branches: [ "7.2", "7.3", "7.4", "8.1" ]
pull_request:
branches: [ "7.2", "7.3", "7.4", "8.1" ]
workflow_dispatch:
inputs:
logLevel:
description: 'Log level'
required: true
default: 'warning'
type: choice
options:
- info
- warning
- debug
schedule:
- cron: "0 2 * * *"
jobs:
docker:
runs-on: ubuntu-latest
steps:
- name: Extract branch name
shell: bash
run: echo "##[set-output name=branch;]$(echo ${GITHUB_REF#refs/heads/})"
id: extract_branch
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Login to DockerHub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push
uses: docker/build-push-action@v3
with:
pull: true
push: true
tags: phoenixmedia/nginx-php:${{ steps.extract_branch.outputs.branch }}