Skip to content

Commit a09368a

Browse files
authored
add container-images notifications workflow (#33)
1 parent 78394fd commit a09368a

File tree

3 files changed

+44
-7
lines changed

3 files changed

+44
-7
lines changed
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: notify container-images
2+
3+
on:
4+
push:
5+
branches: ['**']
6+
tags: ['[0-9][0-9][0-9][0-9].*']
7+
8+
jobs:
9+
dispatch:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- name: Determine Image Flavor
13+
id: vars
14+
run: |
15+
if [[ "${{ github.ref }}" == refs/tags/* ]]; then
16+
echo "tag=${{ github.ref_name }}" >> $GITHUB_OUTPUT
17+
echo "type=version" >> $GITHUB_OUTPUT
18+
elif [[ "${{ github.ref }}" == refs/heads/main ]]; then
19+
echo "tag=latest" >> $GITHUB_OUTPUT
20+
echo "type=rolling" >> $GITHUB_OUTPUT
21+
else
22+
# Any other branch (feature/fix/dev) is tagged as 'dev'
23+
echo "tag=dev" >> $GITHUB_OUTPUT
24+
echo "type=rolling" >> $GITHUB_OUTPUT
25+
fi
26+
27+
- name: Repository Dispatch
28+
uses: peter-evans/repository-dispatch@v3
29+
with:
30+
token: ${{ secrets.MAPCHETE_PAT_CONTAINER_IMAGES_TOKEN }}
31+
repository: mapchete/container-images
32+
event-type: source_update
33+
client-payload: |
34+
{
35+
"source_repo": "${{ github.event.repository.name }}",
36+
"image_tag": "${{ steps.vars.outputs.tag }}",
37+
"type": "${{ steps.vars.outputs.type }}",
38+
"sha": "${{ github.sha }}"
39+
}

.github/workflows/python-package.yml

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ on:
77
branches: [main]
88
schedule:
99
- cron: '0 8 * * 1,4'
10-
workflow_call: # This allows sync-dependencies.yml to trigger this logic
10+
workflow_call:
1111

1212
permissions:
1313
pull-requests: write
@@ -20,18 +20,16 @@ jobs:
2020
fail-fast: false
2121
matrix:
2222
python-version: ["3.10", "3.11", "3.12", "3.13"]
23-
os: ["ubuntu-latest"] # Simplified to ubuntu-latest for reliability
23+
os: ["ubuntu-latest"]
2424

2525
steps:
2626
- uses: actions/checkout@v4
2727

28-
# --- CRITICAL FOR SYNC ---
2928
- name: Download updated dependencies
3029
uses: actions/download-artifact@v4
31-
continue-on-error: true # Safe to fail if running normally on push/PR
30+
continue-on-error: true
3231
with:
3332
name: updated-deps
34-
# -------------------------
3533

3634
- name: Set up Python ${{ matrix.python-version }}
3735
uses: actions/setup-python@v5

README.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,10 +40,10 @@ You must have ``mapchete`` with ``s3`` installed, so let's grab the ``complete``
4040

4141
.. code-block:: bash
4242
43-
pip install mapchete[complete]
43+
uv pip install mapchete[complete]
4444
4545
Then install mapchete-eo:
4646

4747
.. code-block:: bash
4848
49-
pip install mapchete-eo
49+
uv pip install mapchete-eo

0 commit comments

Comments
 (0)