Skip to content

test docker workflow #3

test docker workflow

test docker workflow #3

name: Release Docker EE
on:
workflow_run:
workflows: [Disabled-Release NPM]
types:
- completed
push:
branches:
- 'release/**'
jobs:
docker:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [14.x]
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Set Current Version
run: |
CURRENT_VERSION=$(node -p 'require("./lerna.json").version')
echo "CURRENT_VERSION=${CURRENT_VERSION}" >> $GITHUB_ENV
echo "CURRENT_VERSION=${CURRENT_VERSION}"
- uses: docker/setup-qemu-action@v1
- uses: docker/setup-buildx-action@v1
with:
driver-opts: network=host
- name: Docker meta
id: meta
uses: docker/metadata-action@v4
with:
images: |
steedos/steedos-enterprise
tags: |
type=ref,event=branch
type=ref,event=pr
type=schedule
type=semver,pattern={{version}},value=${CURRENT_VERSION}
type=semver,pattern={{major}}.{{minor}},value=${CURRENT_VERSION}
type=semver,pattern={{major}},value=${CURRENT_VERSION}
- uses: docker/login-action@v1
name: Login Docker Hub
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Build and push docker
uses: docker/build-push-action@v3
with:
context: ./deploy/enterprise
platforms: linux/amd64,linux/arm64
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}