|
1 | | -name: Build and Push Meet image |
| 1 | +name: Build and Push Meet Image |
2 | 2 |
|
3 | 3 | on: |
4 | 4 | push: |
5 | 5 | branches: |
6 | 6 | - develop |
7 | | - paths: |
8 | | - - "meet/**" |
9 | | - - "frontend/**" |
10 | | - - "realtime/**" |
11 | | - - "pyproject.toml" |
| 7 | + - deploy |
| 8 | + # paths: |
| 9 | + # - "meet/**" |
| 10 | + # - "frontend/**" |
| 11 | + # - "realtime/**" |
| 12 | + # - "pyproject.toml" |
12 | 13 | workflow_dispatch: |
13 | 14 | inputs: |
14 | 15 | tag: |
15 | 16 | description: "Image tag (default: latest)" |
16 | 17 | required: false |
17 | 18 | default: "latest" |
18 | 19 |
|
19 | | -env: |
20 | | - REGISTRY: ghcr.io |
21 | | - IMAGE_NAME: frappe/meet |
22 | | - |
23 | 20 | jobs: |
24 | 21 | build-and-push: |
25 | | - runs-on: ubuntu-latest |
26 | 22 | permissions: |
27 | 23 | contents: read |
28 | 24 | packages: write |
29 | | - |
30 | | - steps: |
31 | | - - name: Checkout meet |
32 | | - uses: actions/checkout@v4 |
33 | | - |
34 | | - - name: Checkout frappe_docker |
35 | | - uses: actions/checkout@v4 |
36 | | - with: |
37 | | - repository: frappe/frappe_docker |
38 | | - path: frappe_docker |
39 | | - |
40 | | - - name: Prepare apps.json |
41 | | - run: | |
42 | | - echo '[{"url":"https://github.com/frappe/meet","branch":"'"$GITHUB_REF_NAME"'"}]' > apps.json |
43 | | -
|
44 | | - - name: Set up Docker Buildx |
45 | | - uses: docker/setup-buildx-action@v3 |
46 | | - |
47 | | - - name: Log in to GHCR |
48 | | - uses: docker/login-action@v3 |
49 | | - with: |
50 | | - registry: ${{ env.REGISTRY }} |
51 | | - username: ${{ github.actor }} |
52 | | - password: ${{ secrets.GITHUB_TOKEN }} |
53 | | - |
54 | | - - name: Extract metadata |
55 | | - id: meta |
56 | | - uses: docker/metadata-action@v5 |
57 | | - with: |
58 | | - images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} |
59 | | - tags: | |
60 | | - type=raw,value=latest |
61 | | - type=ref,event=branch |
62 | | - type=raw,value=${{ github.event.inputs.tag || 'latest' }},enable=${{ github.event_name == 'workflow_dispatch' }} |
63 | | - type=sha,prefix=,format=short |
64 | | -
|
65 | | - - name: Inject Cache Buster |
66 | | - run: | |
67 | | - sed -i 's/RUN --mount=type=secret,id=apps_json/ARG CACHE_BUSTER\nRUN echo "Cache Buster: $CACHE_BUSTER"\nRUN --mount=type=secret,id=apps_json/' frappe_docker/images/custom/Containerfile |
68 | | -
|
69 | | - - name: Build and push Docker image |
70 | | - uses: docker/build-push-action@v6 |
71 | | - with: |
72 | | - context: frappe_docker |
73 | | - file: frappe_docker/images/custom/Containerfile |
74 | | - push: true |
75 | | - tags: ${{ steps.meta.outputs.tags }} |
76 | | - labels: ${{ steps.meta.outputs.labels }} |
77 | | - build-args: | |
78 | | - CACHE_BUSTER=${{ github.sha }} |
79 | | - secret-files: | |
80 | | - apps_json=${{ github.workspace }}/apps.json |
81 | | - cache-from: type=gha |
82 | | - cache-to: type=gha,mode=max |
| 25 | + uses: frappe/frappe_docker/.github/workflows/app-build-image.yml@main |
| 26 | + with: |
| 27 | + app_name: meet |
| 28 | + app_repo: frappe/meet |
| 29 | + app_ref: ${{ github.ref_name }} |
| 30 | + frappe_ref: develop |
| 31 | + frappe_image_prefix: ghcr.io/frappe |
| 32 | + image_name: ghcr.io/frappe/meet |
| 33 | + image_tag: ${{ github.event.inputs.tag || github.ref_name }} |
| 34 | + registry: ghcr.io |
| 35 | + push: true |
| 36 | + platforms: linux/amd64 |
0 commit comments