0
Fork 0
mirror of https://github.com/verdaccio/verdaccio.git synced 2024-12-16 21:56:25 -05:00
verdaccio/.github/workflows/docker-publish.yml
Juan Picado f168b2512e
chore: disable yarn local cache enableGlobalCache (#2254)
* chore: add yarn local  cache

* update list files docker publish

* add example extending with plugins and yarn2
2021-05-14 08:04:19 +02:00

55 lines
1.4 KiB
YAML

name: Docker publish to docker.io
on:
push:
paths:
- .github/workflows/docker-publish.yml
- 'src/**'
- 'conf/**'
- 'types/**'
- 'docker-bin/**'
- 'bin/**'
- 'package.json'
- 'yarn.lock'
- '.yarn/**'
- '.yarnrc.yaml'
- '.pnp.js'
branches:
- '**'
tags:
- 'v*'
jobs:
docker:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: docker/setup-qemu-action@v1
- uses: docker/setup-buildx-action@v1
with:
driver-opts: network=host
- uses: docker/login-action@v1
name: Login Docker Hub
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Prepare docker image tags
id: docker_meta
uses: crazy-max/ghaction-docker-meta@v1
with:
images: ${{ github.repository }}
tag-custom: 5.x-next
tag-custom-only: ${{ github.ref == 'refs/heads/5.x' }}
tag-semver: |
{{version}}
{{major}}
{{major}}.{{minor}}
- name: Build & Push
uses: docker/build-push-action@v2
with:
context: .
file: ./Dockerfile
platforms: linux/amd64,linux/arm64
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.docker_meta.outputs.tags }}
labels: ${{ steps.docker_meta.outputs.labels }}