-
Notifications
You must be signed in to change notification settings - Fork 444
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ci: use reusable workflow for MacOs build #9392
base: main
Are you sure you want to change the base?
Changes from 9 commits
9814b7c
f977a62
10be4cb
bd517b1
fbc6b7f
e47c846
f5e21b9
44c1f52
350ae9a
9da0b4d
e86abd8
b2cf879
3ab7297
fb05a2e
22963c7
57f5880
7ee766c
73f494a
3bb61ce
c4ddac3
8c9bf3e
eb8a87d
1bf8857
441e769
3a3fcb3
8d81c83
aa19a41
d133f83
723a791
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
name: Check neon with MacOS builds | ||
|
||
on: | ||
workflow_call: | ||
|
||
env: | ||
RUST_BACKTRACE: 1 | ||
COPT: '-Werror' | ||
|
||
# TODO: move `check-*` and `files-changed` jobs to the "Caller" Workflow | ||
# We should care about that as Github has limitations: | ||
# - You can connect up to four levels of workflows | ||
# - You can call a maximum of 20 unique reusable workflows from a single workflow file. | ||
# https://docs.github.com/en/actions/sharing-automations/reusing-workflows#limitations | ||
jobs: | ||
files-changed: | ||
name: Detect what files changed | ||
runs-on: ubuntu-22.04 | ||
timeout-minutes: 3 | ||
outputs: | ||
postgres_changes: ${{ steps.postgres_changes.outputs.changes }} | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@6ccd57f4c5d15bdc2fef309bd9fb6cc9db2ef1c6 # v4.1.7 | ||
with: | ||
submodules: true | ||
|
||
- name: Check for Postgres changes | ||
uses: dorny/paths-filter@1441771bbfdd59dcd748680ee64ebd8faab1a242 #v3 | ||
id: postgres_changes | ||
with: | ||
token: ${{ github.token }} | ||
filters: | | ||
postgres-v14: ['vendor/postgres-v14/**', 'Makefile', '.github/workflows/build-macos.yml', 'pgxn/**'] | ||
postgres-v15: ['vendor/postgres-v15/**', 'Makefile', '.github/workflows/build-macos.yml', 'pgxn/**'] | ||
postgres-v16: ['vendor/postgres-v16/**', 'Makefile', '.github/workflows/build-macos.yml', 'pgxn/**'] | ||
postgres-v17: ['vendor/postgres-v17/**', 'Makefile', '.github/workflows/build-macos.yml', 'pgxn/**'] | ||
base: ${{ github.event_name != 'pull_request' && (github.event.merge_group.base_ref || github.ref_name) || '' }} | ||
ref: ${{ github.event_name != 'pull_request' && (github.event.merge_group.head_ref || github.ref) || ''}} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I was thinking about having this part in the main We might want to consider using https://github.com/tj-actions/changed-files (instead of |
||
|
||
check-macos-build: | ||
needs: [ files-changed ] | ||
if: | | ||
contains(github.event.pull_request.labels.*.name, 'run-extra-build-macos') || | ||
contains(github.event.pull_request.labels.*.name, 'run-extra-build-*') || | ||
github.ref_name == 'main' | ||
timeout-minutes: 30 | ||
runs-on: macos-14 | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I've find out, that There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. sounds good, done There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. seems something has changed in Github runners, as build started to fail on both I will anyway get back to |
||
strategy: | ||
matrix: | ||
postgres-version: ${{ fromJSON(needs.files-changed.outputs.postgres_changes) }} | ||
env: | ||
# Use release build only, to have less debug info around | ||
# Hence keeping target/ (and general cache size) smaller | ||
BUILD_TYPE: release | ||
steps: | ||
- name: Checkout with ${{ matrix.postgres-version }} Submodule | ||
uses: actions/checkout@v4 | ||
with: | ||
submodules: true | ||
sparse-checkout: | | ||
vendor/${{ matrix.postgres-version }} | ||
|
||
- name: Build ${{ matrix.postgres-version }} | ||
run: | | ||
echo make ${{ matrix.postgres-version }} | ||
echo make $(echo "${{ matrix.postgres-version }}" | sed -e 's/postgres-/neon-pg-ext-/') |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,7 +6,7 @@ on: | |
- main | ||
- release | ||
- release-proxy | ||
pull_request: | ||
# pull_request: | ||
|
||
defaults: | ||
run: | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
# pgxs/neon/Makefile | ||
# Test to trigger changes 2 | ||
|
||
|
||
MODULE_big = neon | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We're ok to use the latest tag (like
@v4
) for "official" actions fromactions
org