-
Notifications
You must be signed in to change notification settings - Fork 43
44 lines (38 loc) · 1.31 KB
/
development.yml
File metadata and controls
44 lines (38 loc) · 1.31 KB
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
39
40
41
42
43
44
name: Development
on:
push:
branches:
- development
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- uses: Azure/docker-login@v1
with:
login-server: sparrowprod.azurecr.io
username: ${{ secrets.REGISTRY_USERNAME }}
password: ${{ secrets.REGISTRY_PASSWORD }}
- run: |
docker build . -t sparrowprod.azurecr.io/sparrow-api:${{ github.run_number }} --build-arg GITHUB_TOKEN=${{ secrets.SPARROW_GITHUB_TOKEN }}
docker push sparrowprod.azurecr.io/sparrow-api:${{ github.run_number }}
deploy:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- uses: richardrigutins/replace-in-files@v1
with:
files: "./deploymentManifests/deployment.yml"
search-text: '_BUILD__ID_'
replacement-text: '${{ github.run_number }}'
- uses: azure/setup-kubectl@v2.0
- uses: Azure/k8s-set-context@v2
with:
kubeconfig: ${{ secrets.KUBE_CONFIG }}
- uses: Azure/k8s-deploy@v4
with:
action: deploy
namespace: sparrow-dev
manifests: |
./deploymentManifests/deployment.yml