-
Notifications
You must be signed in to change notification settings - Fork 0
38 lines (33 loc) · 932 Bytes
/
deploy.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
30
31
32
33
34
35
36
37
38
name: Docker Build and Kubernetes Deploy
on:
workflow_dispatch:
jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Configure kubectl
run: |
mkdir -p ~/.kube
echo "$KUBE_CONFIG" | base64 -d > ~/.kube/config
kubectl version --client
- name: Create and claim persistent volume
run: |
cd kubernetes
whoami
sudo su
kubectl apply -f persistentVolume.yaml
kubectl apply -f persistentVolumeClaim.yaml
- name: Deploy MongoDB
run: |
kubectl apply -f mongodb.yaml
- name: Deploy Redis
run: |
kubectl apply -f redis.yaml
- name: Deploy Backend
run: |
kubectl apply -f backend.yaml
- name: Deploy Frontend
run: |
kubectl apply -f frontend.yaml