-
Notifications
You must be signed in to change notification settings - Fork 29
71 lines (59 loc) · 3.07 KB
/
sampleimages.yaml
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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
name: SampleImages
on:
workflow_dispatch:
permissions: write-all
env:
ContainerRegistry: "ghcr.io"
ContainerRegistryRepo: "ghcr.io/eclipse-symphony"
jobs:
build:
if: github.repository == 'eclipse-symphony/symphony' && (github.actor == 'chgennar' || github.actor == 'juancooldude' || github.actor == 'Haishi2016' || github.actor == 'nonsocode' || github.actor == 'msftcoderdjw' || github.actor == 'TonyXiaofeng' || github.actor == 'RemindD')
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
registry: ${{ env.ContainerRegistry }}
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Set up Go
uses: actions/setup-go@v3
with:
go-version: 1.19 # Replace with your desired Go version
- name: Read Version
id: read_version
run: |
version=$(cat .github/version/versions.txt)
echo "version=$version" >> $GITHUB_OUTPUT
- name: Build flask app
run: |
cd docs/samples/sample-payload-flask
docker build -t ${{ env.ContainerRegistryRepo }}/sample-flask-app:${{ steps.read_version.outputs.version }} .
- name: Build python sdk
run: |
cd sdks/python-sdk
docker build -t ${{ env.ContainerRegistryRepo }}/symphony-python-sdk:${{ steps.read_version.outputs.version }} .
- name: Build akri
run: |
cd docs/samples/akri-discover-job
go build -o discover-job
docker build -t ${{ env.ContainerRegistryRepo }}/symphony-akri:${{ steps.read_version.outputs.version }} -f ./Dockerfile.microsoft .
- name: Push sample-flask-app images
run: |
docker push ${{ env.ContainerRegistryRepo }}/sample-flask-app:${{ steps.read_version.outputs.version }}
docker tag ${{ env.ContainerRegistryRepo }}/sample-flask-app:${{ steps.read_version.outputs.version }} ${{ env.ContainerRegistryRepo }}/sample-flask-app:latest
docker push ${{ env.ContainerRegistryRepo }}/sample-flask-app:latest
- name: Push symphony-python-sdk images
run: |
docker push ${{ env.ContainerRegistryRepo }}/symphony-python-sdk:${{ steps.read_version.outputs.version }}
docker tag ${{ env.ContainerRegistryRepo }}/symphony-python-sdk:${{ steps.read_version.outputs.version }} ${{ env.ContainerRegistryRepo }}/symphony-python-sdk:latest
docker push ${{ env.ContainerRegistryRepo }}/symphony-python-sdk:latest
- name: Push symphony-akri images
run: |
docker push ${{ env.ContainerRegistryRepo }}/symphony-akri:${{ steps.read_version.outputs.version }}
docker tag ${{ env.ContainerRegistryRepo }}/symphony-akri:${{ steps.read_version.outputs.version }} ${{ env.ContainerRegistryRepo }}/symphony-akri:latest
docker push ${{ env.ContainerRegistryRepo }}/symphony-akri:latest