File tree Expand file tree Collapse file tree 2 files changed +37
-0
lines changed Expand file tree Collapse file tree 2 files changed +37
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Production deploy 
2+ on :
3+   workflow_dispatch :  #  click the button on Github repo!
4+ 
5+ jobs :
6+   #  This workflow contains a single job called "build"
7+   build :
8+     #  The type of runner that the job will run on
9+     runs-on : ubuntu-latest 
10+     strategy :
11+       matrix :
12+         python-version : [3.6] 
13+ 
14+     #  Steps represent a sequence of tasks that will be executed as part of the job
15+     steps :
16+     - uses : actions/checkout@v2  
17+     - name : Install dependencies for kubectl 
18+       run : | 
19+         curl -LO https://storage.googleapis.com/kubernetes-release/release/`curl -s https://storage.googleapis.com/kubernetes-release/release/stable.txt`/bin/linux/amd64/kubectl 
20+         chmod +x ./kubectl 
21+         sudo mv ./kubectl /usr/local/bin/kubectl 
22+ 
23+ name : Deploy in production 
24+       env :
25+         GOOGLE_APPLICATION_CREDENTIALS : ${{ secrets.GOOGLE_APPLICATION_CREDENTIALS }} 
26+       run : | 
27+         echo "$GOOGLE_APPLICATION_CREDENTIALS" | base64 --decode > /tmp/config 
28+         export GOOGLE_APPLICATION_CREDENTIALS=/tmp/config 
29+         export KUBECONFIG=deployments/promhub_kubeconfig 
30+         chmod +x deployments/kubernetes/master/deploy.sh 
31+         sh ./deployments/kubernetes/master/deploy.sh 
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+ kubectl version --client
3+ kubectl -n promhub get po
4+ kubectl -n promhub delete po -l app=backend
5+ kubectl apply -f deployments/master/backend-deployment.yaml
6+ kubectl -n promhub get po
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments