2022-02-08 08:35:52 +00:00
|
|
|
name: Bench
|
|
|
|
|
|
|
|
on:
|
|
|
|
pull_request:
|
|
|
|
branches:
|
|
|
|
- main
|
|
|
|
paths:
|
2022-03-14 05:53:03 +00:00
|
|
|
- images/bench/**
|
2022-02-08 08:35:52 +00:00
|
|
|
- docker-bake.hcl
|
|
|
|
|
|
|
|
schedule:
|
|
|
|
# Every day at 12:00 pm
|
|
|
|
- cron: 0 0 * * *
|
|
|
|
|
|
|
|
workflow_dispatch:
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2022-03-04 19:35:27 +00:00
|
|
|
uses: actions/checkout@v3
|
2022-02-08 08:35:52 +00:00
|
|
|
|
|
|
|
- name: Setup Buildx
|
|
|
|
uses: docker/setup-buildx-action@v1
|
|
|
|
|
|
|
|
- name: Build and test
|
2022-02-16 06:05:23 +00:00
|
|
|
uses: docker/bake-action@v1.7.0
|
2022-02-08 08:35:52 +00:00
|
|
|
with:
|
|
|
|
targets: bench-test
|
|
|
|
|
|
|
|
- name: Login
|
|
|
|
if: ${{ github.repository == 'frappe/frappe_docker' && github.event_name != 'pull_request' }}
|
|
|
|
uses: docker/login-action@v1
|
|
|
|
with:
|
|
|
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
|
|
|
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
|
|
|
|
|
|
|
- name: Push
|
|
|
|
if: ${{ github.repository == 'frappe/frappe_docker' && github.event_name != 'pull_request' }}
|
2022-02-16 06:05:23 +00:00
|
|
|
uses: docker/bake-action@v1.7.0
|
2022-02-08 08:35:52 +00:00
|
|
|
with:
|
|
|
|
targets: bench
|
|
|
|
push: true
|