fix: Improve workflow for main branch and PRs (#17)
This makes it so that the main branch will push images but PRs won't. This also puts integration tests back in the `+all` target.
This commit is contained in:
parent
c32a0604ce
commit
097dbb391a
4 changed files with 38 additions and 7 deletions
12
.github/workflows/build.yml
vendored
12
.github/workflows/build.yml
vendored
|
|
@ -1,9 +1,7 @@
|
|||
name: Earthly +build
|
||||
name: Earthly main branch +build
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
merge_group:
|
||||
pull_request:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
|
|
@ -15,17 +13,19 @@ jobs:
|
|||
build:
|
||||
permissions:
|
||||
packages: write
|
||||
timeout-minutes: 30
|
||||
timeout-minutes: 60
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: earthly/actions-setup@v1
|
||||
with:
|
||||
use-cache: true
|
||||
version: v0.8.0
|
||||
version: v0.8.2
|
||||
|
||||
# Setup repo and add caching
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
ref: main
|
||||
|
||||
- name: Login to GitHub Container Registry
|
||||
uses: docker/login-action@v3
|
||||
|
|
@ -35,4 +35,4 @@ jobs:
|
|||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Run build
|
||||
run: earthly --push --ci -P +all
|
||||
run: earthly --push --ci -P +build
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue