docker: 安装yarn 1.22 版本 #20
Workflow file for this run
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: 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: | | |
STEEDOS_VERSION=$(node -p 'require("./lerna.json").version') | |
echo "STEEDOS_VERSION=${STEEDOS_VERSION}" >> $GITHUB_ENV | |
echo "STEEDOS_VERSION=${STEEDOS_VERSION}" | |
- name: Generate info.json | |
run: | | |
if [[ -f deploy/enterprise/scripts/generate_info_json.sh ]]; then | |
deploy/enterprise/scripts/generate_info_json.sh | |
fi | |
- 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=semver,pattern={{version}},value=${{ env.STEEDOS_VERSION }} | |
type=semver,pattern={{major}}.{{minor}},value=${{ env.STEEDOS_VERSION }} | |
type=semver,pattern={{major}},value=${{ env.STEEDOS_VERSION }} | |
- uses: docker/login-action@v1 | |
name: Login Docker Hub | |
with: | |
username: ${{ secrets.DOCKER_USERNAME }} | |
password: ${{ secrets.DOCKER_PASSWORD }} | |
- name: Replace Version ~2.5 to Tag | |
uses: jacobtomlinson/gha-find-replace@v2 | |
with: | |
include: deploy/enterprise/app/platform/package.json | |
find: "~2.5" | |
replace: ${{env.STEEDOS_VERSION}} | |
regex: false | |
- 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 }} | |