-
Notifications
You must be signed in to change notification settings - Fork 16
29 lines (25 loc) · 941 Bytes
/
webapp.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
name: Publish Web App container image to GitHub
on:
workflow_dispatch:
push:
branches:
- main
paths:
- 'src/Azure.AISearch.WebApp/**'
permissions:
id-token: write
contents: read
jobs:
build:
permissions: write-all
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Build Docker Image
run: docker build --no-cache --build-arg app_version=1.0.$GITHUB_RUN_NUMBER --build-arg source_version=$GITHUB_SHA -t jelledruyts/azure-aisearch-webapp:latest -f ./src/Azure.AISearch.WebApp/Dockerfile ./src/Azure.AISearch.WebApp
- name: Push Docker Image to GitHub
run: |
echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u ${{ github.actor }} --password-stdin
docker tag jelledruyts/azure-aisearch-webapp:latest ghcr.io/jelledruyts/azure-aisearch-webapp:latest
docker push ghcr.io/jelledruyts/azure-aisearch-webapp:latest