mirror of
https://github.com/frappe/frappe_docker.git
synced 2024-11-10 07:11:00 +00:00
66fca59f74
Bumps [docker/bake-action](https://github.com/docker/bake-action) from 1.6.0 to 1.7.0. - [Release notes](https://github.com/docker/bake-action/releases) - [Commits](https://github.com/docker/bake-action/compare/v1.6.0...v1.7.0) --- updated-dependencies: - dependency-name: docker/bake-action dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
142 lines
3.5 KiB
YAML
142 lines
3.5 KiB
YAML
name: Build Stable
|
|
|
|
on:
|
|
pull_request:
|
|
branches:
|
|
- main
|
|
paths:
|
|
- .github/workflows/build_stable.yml
|
|
- .github/scripts/get-latest-tags.sh
|
|
- build/**
|
|
- installation/**
|
|
- tests/**
|
|
- .dockerignore
|
|
- docker-bake.hcl
|
|
- env-example
|
|
|
|
push:
|
|
branches:
|
|
- main
|
|
paths:
|
|
- .github/workflows/build_stable.yml
|
|
- .github/scripts/get-latest-tags.sh
|
|
- build/**
|
|
- installation/**
|
|
- tests/**
|
|
- .dockerignore
|
|
- docker-bake.hcl
|
|
- env-example
|
|
|
|
# Triggered from frappe/frappe and frappe/erpnext on releases
|
|
repository_dispatch:
|
|
|
|
workflow_dispatch:
|
|
|
|
env:
|
|
IS_AUTHORIZED_RUN: ${{ github.repository == 'frappe/frappe_docker' && github.event_name != 'pull_request' }}
|
|
|
|
jobs:
|
|
build:
|
|
name: Frappe & ERPNext
|
|
runs-on: ubuntu-latest
|
|
strategy:
|
|
matrix:
|
|
version: [12, 13]
|
|
services:
|
|
registry:
|
|
image: registry:2
|
|
ports:
|
|
- 5000:5000
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v2
|
|
|
|
- name: Setup Buildx
|
|
uses: docker/setup-buildx-action@v1
|
|
with:
|
|
driver-opts: network=host
|
|
|
|
- name: Login
|
|
uses: docker/login-action@v1
|
|
if: env.IS_AUTHORIZED_RUN == 'true'
|
|
with:
|
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
|
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
|
|
|
- name: Get latest versions
|
|
run: ./.github/scripts/get-latest-tags.sh
|
|
env:
|
|
VERSION: ${{ matrix.version }}
|
|
|
|
- name: Build Frappe
|
|
uses: docker/bake-action@v1.7.0
|
|
with:
|
|
files: docker-bake.hcl
|
|
targets: frappe-stable-test
|
|
load: true
|
|
|
|
- name: Push Frappe to local registry
|
|
uses: docker/bake-action@v1.7.0
|
|
with:
|
|
files: docker-bake.hcl
|
|
targets: frappe-stable-test-local
|
|
push: true
|
|
|
|
- name: Test Frappe
|
|
if: github.event_name == 'pull_request'
|
|
run: ./tests/test-frappe.sh
|
|
|
|
- name: Build ERPNext
|
|
uses: docker/bake-action@v1.7.0
|
|
with:
|
|
files: docker-bake.hcl
|
|
targets: erpnext-stable-test
|
|
load: true
|
|
|
|
- name: Test ERPNext
|
|
if: github.event_name == 'pull_request'
|
|
run: ./tests/test-erpnext.sh
|
|
|
|
- name: Push Frappe
|
|
if: env.IS_AUTHORIZED_RUN == 'true'
|
|
uses: docker/bake-action@v1.7.0
|
|
with:
|
|
files: docker-bake.hcl
|
|
targets: frappe-stable
|
|
push: true
|
|
env:
|
|
GIT_TAG: ${{ env.FRAPPE_VERSION }}
|
|
|
|
- name: Push ERPNext
|
|
if: env.IS_AUTHORIZED_RUN == 'true'
|
|
uses: docker/bake-action@v1.7.0
|
|
with:
|
|
files: docker-bake.hcl
|
|
targets: erpnext-stable
|
|
push: true
|
|
env:
|
|
GIT_TAG: ${{ env.ERPNEXT_VERSION }}
|
|
|
|
release_helm:
|
|
name: Release Helm
|
|
runs-on: ubuntu-latest
|
|
if: github.repository == 'frappe/frappe_docker' && github.event_name != 'pull_request'
|
|
needs: build
|
|
|
|
steps:
|
|
- name: Setup deploy key
|
|
uses: webfactory/ssh-agent@v0.5.4
|
|
with:
|
|
ssh-private-key: ${{ secrets.HELM_DEPLOY_KEY }}
|
|
|
|
- name: Setup Git Credentials
|
|
run: |
|
|
git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com"
|
|
git config --global user.name "github-actions[bot]"
|
|
|
|
- name: Release
|
|
run: |
|
|
git clone git@github.com:frappe/helm.git && cd helm
|
|
pip install -r release_wizard/requirements.txt
|
|
./release_wizard/wizard 13 patch --remote origin --ci
|