Skip to content

Commit 591fc2d

Browse files
committed
Add CI workflows for services (auth, chat, payment, etc.)
1 parent f2b4102 commit 591fc2d

6 files changed

Lines changed: 186 additions & 3 deletions

File tree

.github/workflows/api_build.yml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,4 @@ jobs:
3434
context: ./api-gateway/
3535
platforms: linux/amd64,linux/arm64
3636
push: true
37-
tags: |
38-
javeddev/api-gateway:latest
39-
javeddev/api-gateway:${{ github.sha }}
37+
tags: javedmv/api-gateway:latest

.github/workflows/auth_build.yml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: Build and publish auth service to Docker Hub
2+
3+
on:
4+
push:
5+
branches: ['main']
6+
paths:
7+
- "auth-service/**"
8+
workflow_dispatch:
9+
10+
jobs:
11+
push_to_registry:
12+
name: Push Docker image to Docker Hub
13+
runs-on: ubuntu-latest
14+
15+
steps:
16+
- name: Check out the repo
17+
uses: actions/checkout@v3
18+
19+
- name: Set up QEMU
20+
uses: docker/setup-qemu-action@v2
21+
22+
- name: Set up Docker Buildx
23+
uses: docker/setup-buildx-action@v2
24+
25+
- name: Login to Docker Hub
26+
uses: docker/login-action@v2
27+
with:
28+
username: ${{ secrets.DOCKER_USERNAME }}
29+
password: ${{ secrets.DOCKER_PASSWORD }}
30+
31+
- name: Build and push Docker image
32+
uses: docker/build-push-action@v4
33+
with:
34+
context: ./auth-service/
35+
platforms: linux/amd64,linux/arm64
36+
push: true
37+
tags: javedmv/auth-service:latest

.github/workflows/chat_build.yml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: Build and publish chat service to Docker Hub
2+
3+
on:
4+
push:
5+
branches: ['main']
6+
paths:
7+
- "chat-service/**"
8+
workflow_dispatch:
9+
10+
jobs:
11+
push_to_registry:
12+
name: Push Docker image to Docker Hub
13+
runs-on: ubuntu-latest
14+
15+
steps:
16+
- name: Check out the repo
17+
uses: actions/checkout@v3
18+
19+
- name: Set up QEMU
20+
uses: docker/setup-qemu-action@v2
21+
22+
- name: Set up Docker Buildx
23+
uses: docker/setup-buildx-action@v2
24+
25+
- name: Login to Docker Hub
26+
uses: docker/login-action@v2
27+
with:
28+
username: ${{ secrets.DOCKER_USERNAME }}
29+
password: ${{ secrets.DOCKER_PASSWORD }}
30+
31+
- name: Build and push Docker image
32+
uses: docker/build-push-action@v4
33+
with:
34+
context: ./chat-service/
35+
platforms: linux/amd64,linux/arm64
36+
push: true
37+
tags: javedmv/chat-service:latest

.github/workflows/course_build.yml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: Build and publish course srv to Docker Hub
2+
3+
on:
4+
push:
5+
branches: ['main']
6+
paths:
7+
- "course-srv/**"
8+
workflow_dispatch:
9+
10+
jobs:
11+
push_to_registry:
12+
name: Push Docker image to Docker Hub
13+
runs-on: ubuntu-latest
14+
15+
steps:
16+
- name: Check out the repo
17+
uses: actions/checkout@v3
18+
19+
- name: Set up QEMU
20+
uses: docker/setup-qemu-action@v2
21+
22+
- name: Set up Docker Buildx
23+
uses: docker/setup-buildx-action@v2
24+
25+
- name: Login to Docker Hub
26+
uses: docker/login-action@v2
27+
with:
28+
username: ${{ secrets.DOCKER_USERNAME }}
29+
password: ${{ secrets.DOCKER_PASSWORD }}
30+
31+
- name: Build and push Docker image
32+
uses: docker/build-push-action@v4
33+
with:
34+
context: ./course-srv/
35+
platforms: linux/amd64,linux/arm64
36+
push: true
37+
tags: javedmv/course-srv:latest
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: Build and publish notification service to Docker Hub
2+
3+
on:
4+
push:
5+
branches: ['main']
6+
paths:
7+
- "notification-service/**"
8+
workflow_dispatch:
9+
10+
jobs:
11+
push_to_registry:
12+
name: Push Docker image to Docker Hub
13+
runs-on: ubuntu-latest
14+
15+
steps:
16+
- name: Check out the repo
17+
uses: actions/checkout@v3
18+
19+
- name: Set up QEMU
20+
uses: docker/setup-qemu-action@v2
21+
22+
- name: Set up Docker Buildx
23+
uses: docker/setup-buildx-action@v2
24+
25+
- name: Login to Docker Hub
26+
uses: docker/login-action@v2
27+
with:
28+
username: ${{ secrets.DOCKER_USERNAME }}
29+
password: ${{ secrets.DOCKER_PASSWORD }}
30+
31+
- name: Build and push Docker image
32+
uses: docker/build-push-action@v4
33+
with:
34+
context: ./notification-service/
35+
platforms: linux/amd64,linux/arm64
36+
push: true
37+
tags: javedmv/notification-service:latest
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: Build and publish payment srv to Docker Hub
2+
3+
on:
4+
push:
5+
branches: ['main']
6+
paths:
7+
- "payment-srv/**"
8+
workflow_dispatch:
9+
10+
jobs:
11+
push_to_registry:
12+
name: Push Docker image to Docker Hub
13+
runs-on: ubuntu-latest
14+
15+
steps:
16+
- name: Check out the repo
17+
uses: actions/checkout@v3
18+
19+
- name: Set up QEMU
20+
uses: docker/setup-qemu-action@v2
21+
22+
- name: Set up Docker Buildx
23+
uses: docker/setup-buildx-action@v2
24+
25+
- name: Login to Docker Hub
26+
uses: docker/login-action@v2
27+
with:
28+
username: ${{ secrets.DOCKER_USERNAME }}
29+
password: ${{ secrets.DOCKER_PASSWORD }}
30+
31+
- name: Build and push Docker image
32+
uses: docker/build-push-action@v4
33+
with:
34+
context: ./payment-srv/
35+
platforms: linux/amd64,linux/arm64
36+
push: true
37+
tags: javedmv/payment-srv:latest

0 commit comments

Comments
 (0)