From f7ee0eac3cf521e52e5ee2ae1c649b37d1db611d Mon Sep 17 00:00:00 2001 From: AndreEickenberg <123386634+AndreEickenberg@users.noreply.github.com> Date: Mon, 23 Jan 2023 16:45:47 +0100 Subject: [PATCH 1/3] Update app.py --- app.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app.py b/app.py index 7f8a1f2e8..d94ec5600 100644 --- a/app.py +++ b/app.py @@ -3,4 +3,4 @@ @app.route("/") def hello(): - return "Hello, World!" + return "Hello, World!!!" From 111c8d3133902b49f34b51dcf98d4b478013227c Mon Sep 17 00:00:00 2001 From: AndreEickenberg <123386634+AndreEickenberg@users.noreply.github.com> Date: Tue, 24 Jan 2023 10:23:41 +0100 Subject: [PATCH 2/3] Add or update the Azure App Service build and deployment workflow config --- .../workflows/master_deployment-test-ae.yml | 63 +++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 .github/workflows/master_deployment-test-ae.yml diff --git a/.github/workflows/master_deployment-test-ae.yml b/.github/workflows/master_deployment-test-ae.yml new file mode 100644 index 000000000..a7af997fe --- /dev/null +++ b/.github/workflows/master_deployment-test-ae.yml @@ -0,0 +1,63 @@ +# Docs for the Azure Web Apps Deploy action: https://github.com/Azure/webapps-deploy +# More GitHub Actions for Azure: https://github.com/Azure/actions +# More info on Python, GitHub Actions, and Azure App Service: https://aka.ms/python-webapps-actions + +name: Build and deploy Python app to Azure Web App - Deployment-Test-AE + +on: + push: + branches: + - master + workflow_dispatch: + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + + - name: Set up Python version + uses: actions/setup-python@v1 + with: + python-version: '3.8' + + - name: Create and start virtual environment + run: | + python -m venv venv + source venv/bin/activate + + - name: Install dependencies + run: pip install -r requirements.txt + + # Optional: Add step to run tests here (PyTest, Django test suites, etc.) + + - name: Upload artifact for deployment jobs + uses: actions/upload-artifact@v2 + with: + name: python-app + path: | + . + !venv/ + + deploy: + runs-on: ubuntu-latest + needs: build + environment: + name: 'Production' + url: ${{ steps.deploy-to-webapp.outputs.webapp-url }} + + steps: + - name: Download artifact from build job + uses: actions/download-artifact@v2 + with: + name: python-app + path: . + + - name: 'Deploy to Azure Web App' + uses: azure/webapps-deploy@v2 + id: deploy-to-webapp + with: + app-name: 'Deployment-Test-AE' + slot-name: 'Production' + publish-profile: ${{ secrets.AZUREAPPSERVICE_PUBLISHPROFILE_688DB0E30EB94F3CBC74F34CA419DC7D }} From 7ff9b64a60331e318c0db2bd2dcd3a19f4d38f18 Mon Sep 17 00:00:00 2001 From: AndreEickenberg <123386634+AndreEickenberg@users.noreply.github.com> Date: Tue, 24 Jan 2023 17:17:05 +0100 Subject: [PATCH 3/3] Update app.py --- app.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app.py b/app.py index d94ec5600..7f8a1f2e8 100644 --- a/app.py +++ b/app.py @@ -3,4 +3,4 @@ @app.route("/") def hello(): - return "Hello, World!!!" + return "Hello, World!"