|
5 | 5 | repositoryName: techexcel/dotnetcoreapp
|
6 | 6 | dockerFolderPath: ./src/Application/src/RazorPagesTestSample
|
7 | 7 | tag: ${{github.run_number}}
|
8 |
| - |
| 8 | + |
9 | 9 | on:
|
10 | 10 | push:
|
11 | 11 | branches: [ main ]
|
|
35 | 35 | run: dotnet test --no-build --verbosity normal ./src/Application/tests/RazorPagesTestSample.Tests/RazorPagesTestSample.Tests.csproj
|
36 | 36 |
|
37 | 37 | dockerBuildPush:
|
38 |
| - |
39 | 38 | runs-on: ubuntu-latest
|
40 | 39 | needs: build
|
41 | 40 |
|
|
61 | 60 |
|
62 | 61 | - name: Docker Push
|
63 | 62 | run: docker push $registryName/$repositoryName:$tag
|
| 63 | + |
| 64 | + deploy-to-dev: |
| 65 | + |
| 66 | + runs-on: ubuntu-latest |
| 67 | + needs: dockerBuildPush |
| 68 | + environment: |
| 69 | + name: dev |
| 70 | + url: https://p5tgcusa4unsu-dev.azurewebsites.net/ |
| 71 | + |
| 72 | + steps: |
| 73 | + - name: 'Login via Azure CLI' |
| 74 | + |
| 75 | + with: |
| 76 | + creds: ${{ secrets.AZURE_CREDENTIALS }} |
| 77 | + |
| 78 | + - uses: azure/webapps-deploy@v2 |
| 79 | + with: |
| 80 | + app-name: 'p5tgcusa4unsu-dev' |
| 81 | + images: p5tgcusa4unsumpnpreg.azurecr.io/techexcel/dotnetcoreapp:${{github.run_number}} |
| 82 | + |
| 83 | + deploy-to-test: |
| 84 | + |
| 85 | + runs-on: ubuntu-latest |
| 86 | + needs: deploy-to-dev |
| 87 | + environment: |
| 88 | + name: test |
| 89 | + url: https://p5tgcusa4unsu-test.azurewebsites.net/ |
| 90 | + |
| 91 | + steps: |
| 92 | + - uses: actions/checkout@v3 |
| 93 | + |
| 94 | + - name: 'Login via Azure CLI' |
| 95 | + |
| 96 | + with: |
| 97 | + creds: ${{ secrets.AZURE_CREDENTIALS }} |
| 98 | + |
| 99 | + - uses: azure/webapps-deploy@v2 |
| 100 | + with: |
| 101 | + app-name: 'p5tgcusa4unsu-test' |
| 102 | + images: p5tgcusa4unsumpnpreg.azurecr.io/techexcel/dotnetcoreapp:${{github.run_number}} |
| 103 | + |
| 104 | + deploy-to-prod: |
| 105 | + |
| 106 | + runs-on: ubuntu-latest |
| 107 | + needs: deploy-to-test |
| 108 | + environment: |
| 109 | + name: prod |
| 110 | + url: https://p5tgcusa4unsu-prod.azurewebsites.net/ |
| 111 | + |
| 112 | + steps: |
| 113 | + - uses: actions/checkout@v3 |
| 114 | + |
| 115 | + - name: 'Login via Azure CLI' |
| 116 | + |
| 117 | + with: |
| 118 | + creds: ${{ secrets.AZURE_CREDENTIALS }} |
| 119 | + |
| 120 | + - uses: azure/webapps-deploy@v2 |
| 121 | + with: |
| 122 | + app-name: 'p5tgcusa4unsu-prod' |
| 123 | + images: p5tgcusa4unsumpnpreg.azurecr.io /techexcel/dotnetcoreapp:${{github.run_number}} |
0 commit comments