Skip to content

Commit d354914

Browse files
committed
Apply CI to whole modules
1 parent eac325a commit d354914

File tree

2 files changed

+48
-35
lines changed

2 files changed

+48
-35
lines changed

.github/workflows/ci-all.yml

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: CI - Build & Push All Microservices
2+
3+
on:
4+
push:
5+
branches: [ main ]
6+
7+
jobs:
8+
build-and-push:
9+
runs-on: ubuntu-latest
10+
11+
steps:
12+
- name: Checkout Code
13+
uses: actions/checkout@v3
14+
15+
- name: Set up Java 17
16+
uses: actions/setup-java@v3
17+
with:
18+
java-version: '17'
19+
distribution: 'temurin'
20+
21+
- name: Build All Services
22+
run: mvn clean install -DskipTests
23+
24+
- name: Set up Docker Buildx
25+
uses: docker/setup-buildx-action@v3
26+
27+
- name: Docker Login
28+
run: echo "${{ secrets.DOCKER_PASSWORD }}" | docker login -u "${{ secrets.DOCKER_USERNAME }}" --password-stdin
29+
30+
- name: Build & Push eureka-server
31+
run: |
32+
docker build -t ${{ secrets.DOCKER_USERNAME }}/eureka-server:latest ./eureka-server
33+
docker push ${{ secrets.DOCKER_USERNAME }}/eureka-server:latest
34+
35+
- name: Build & Push gateway-service
36+
run: |
37+
docker build -t ${{ secrets.DOCKER_USERNAME }}/gateway-service:latest ./gateway-service
38+
docker push ${{ secrets.DOCKER_USERNAME }}/gateway-service:latest
39+
40+
- name: Build & Push payment-service-paypal
41+
run: |
42+
docker build -t ${{ secrets.DOCKER_USERNAME }}/payment-service-paypal:latest ./payment-service-paypal
43+
docker push ${{ secrets.DOCKER_USERNAME }}/payment-service-paypal:latest
44+
45+
- name: Build & Push payment-service-stripe
46+
run: |
47+
docker build -t ${{ secrets.DOCKER_USERNAME }}/payment-service-stripe:latest ./payment-service-stripe
48+
docker push ${{ secrets.DOCKER_USERNAME }}/payment-service-stripe:latest

.ygithub/workflows/ci-docker.yml

Lines changed: 0 additions & 35 deletions
This file was deleted.

0 commit comments

Comments
 (0)