10
10
runs-on : ubuntu-latest
11
11
env :
12
12
ICR_NAMESPACE : solution-tutorials
13
- ICR_REPOSITORY : tutorial-application-log-analysis
13
+ ICR_REPOSITORY_FRONTEND : tutorial-text-analysis-code-engine-frontend
14
+ ICR_REPOSITORY_BACKEND : tutorial-text-analysis-code-engine-backend
15
+ ICR_REPOSITORY_BACKEND_JOB : tutorial-text-analysis-code-engine-backend-job
14
16
steps :
15
17
- name : Check out the repo
16
18
uses : actions/checkout@v2
@@ -23,15 +25,46 @@ jobs:
23
25
password : ${{ secrets.ICR_TOKEN }}
24
26
25
27
- name : Extract metadata (tags, labels) for Docker
26
- id : meta
28
+ id : meta-frontend
27
29
uses : docker/metadata-action@v3.6.2
28
30
with :
29
- images : icr.io/${{ env.ICR_NAMESPACE }}/${{ env.ICR_REPOSITORY }}
31
+ images : icr.io/${{ env.ICR_NAMESPACE }}/${{ env.ICR_REPOSITORY_FRONTEND }}
30
32
31
33
- name : Build and push image
32
34
uses : docker/build-push-action@v2.8.0
33
35
with :
34
- context : .
36
+ context : ./frontend
37
+ file : ./frontend/Dockerfile
35
38
push : true
36
- tags : ${{ steps.meta.outputs.tags }}
37
- labels : ${{ steps.meta.outputs.labels }}
39
+ tags : ${{ steps.meta-frontend.outputs.tags }}
40
+ labels : ${{ steps.meta-frontend.outputs.labels }}
41
+
42
+ - name : Extract metadata (tags, labels) for Docker
43
+ id : meta-backend
44
+ uses : docker/metadata-action@v3.6.2
45
+ with :
46
+ images : icr.io/${{ env.ICR_NAMESPACE }}/${{ env.ICR_REPOSITORY_BACKEND }}
47
+
48
+ - name : Build and push image
49
+ uses : docker/build-push-action@v2.8.0
50
+ with :
51
+ context : ./backend
52
+ file : ./backend/Dockerfile
53
+ push : true
54
+ tags : ${{ steps.meta-backend.outputs.tags }}
55
+ labels : ${{ steps.meta-backend.outputs.labels }}
56
+
57
+ - name : Extract metadata (tags, labels) for Docker
58
+ id : meta-backend-job
59
+ uses : docker/metadata-action@v3.6.2
60
+ with :
61
+ images : icr.io/${{ env.ICR_NAMESPACE }}/${{ env.ICR_REPOSITORY_BACKEND_JOB }}
62
+
63
+ - name : Build and push image
64
+ uses : docker/build-push-action@v2.8.0
65
+ with :
66
+ context : ./jobs
67
+ file : ./jobs/Dockerfile
68
+ push : true
69
+ tags : ${{ steps.meta-backend-job.outputs.tags }}
70
+ labels : ${{ steps.meta-backend-job.outputs.labels }}
0 commit comments