build #40
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: build | |
on: | |
push: | |
branches: | |
- master | |
paths: | |
- vendor/** | |
workflow_dispatch: | |
inputs: | |
projects: | |
required: true | |
description: A list of vendor projects (top level folder in vendors/) separated by spaces. | |
type: string | |
env: | |
REGISTRY: ghcr.io | |
DOCKER_BUILDKIT: 1 | |
COMPOSE_DOCKER_CLI_BUILD: 1 | |
CONTAINER_URL: https://github.com/${{ github.repository }} | |
jobs: | |
build-changed: | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
fetch-depth: 2 | |
- name: docker login | |
uses: docker/login-action@v1 | |
with: | |
registry: ${{ env.REGISTRY }} | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: Set up Docker Buildx | |
id: buildx | |
uses: docker/setup-buildx-action@v1 | |
- name: docker buildx build and push | |
run: ./scripts/build-and-push.sh ${{ inputs.projects }} | |