Skip to content

🔧 Playground for testing GitHub Actions, branch protection rules and Azure Web App deployments.

License

Notifications You must be signed in to change notification settings

philipp-meier/GitHubActionsPlayground

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

39 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🔧 GitHub Actions Playground

Azure Web App Deployment Continuous Integration
Playground for testing ASP.NET Core GitHub Actions and Azure App Service deployments.

Features

  • Simple CI pipeline for pull requests.
  • Branch protection rules for pushing to main (includes executing the CI pipeline).
  • Automated Azure Web App deployment, when pushing to the Server-directory of main.

Azure App Service setup

The Server application was added to Azure with the Azure App Service: Create New Web App... (Advanced) command of the Visual Code extension Azure Tools.
This command creates an Azure App Service-Plan with the required App Service (Web App).

The application can then be deployed with the Azure App Service: Deploy to Web App command of the Azure Tools extension, or with a simple deployment workflow (see azure-webapps-dotnet-core.yml). This requires you to create a repository secret called AZURE_WEBAPP_PUBLISH_PROFILE (Settings -> Security -> Secrets and variables -> Actions -> New repository Secret).

Values entered in the "Secrets and variables"-section are not visible to anyone else. The required publish profile can be downloaded from the Azure portal directly in the corresponding app-service overview page (next to "Start", "Stop", "Refresh" and "Delete").

Initial project setup

  • dotnet new webapi -o Server
  • dotnet new xunit -o Server.Tests
  • dotnet new sln
  • dotnet sln add ./Server/Server.csproj
  • dotnet sln add ./Server.Tests/Server.Tests.csproj
  • dotnet add ./Server.Tests/Server.Tests.csproj reference ./Server/Server.csproj

About

🔧 Playground for testing GitHub Actions, branch protection rules and Azure Web App deployments.

Topics

Resources

License

Stars

Watchers

Forks

Languages