This repository is a demostration on how to use GitHub CodeSpaces customized with DevContainers for modern application development. It leverages AKS plus its Web Application Routing feature and Skaffold.
- Web Application Routing is a developer tool that makes it easier for developers to create dev environments accessible for TLS.
- Skaffold is a continous deployment tool used by developers to automate pushing changes to a Kubernetes cluster.
- DevContainers build consistent developer environments
NOTE:
task up
will create all required Azure resources (locked down to the Codespace's current IP Address) then deploy code viaskaffold run
az login --scope https://graph.microsoft.com/.default
task up
NOTE: Dev Mode will continuously build, test, and deploy changes to your kubernetes cluster when your code changes
task skaffold -- dev
NOTE: Run Mode will build, test, and deploy your code to your kubernetes cluster once
task skaffold -- run
task down
- This will create an AKS cluster and deploy code to it using Skaffold.
- If you are using Codespaces, then after a restart, do:
task update-firewalls
- This will add the Codespaces IP addres to the ACLs for Azure Container Registry, Key Vault and AKS
- Skaffold will automtically run Golang Unit test cases and a Custom curl Test on each build/deploy
- Web Applciation Routing will create an external load balancer and configure an Nginx ingress configured with a self signed certificate
- The Uri will be in the form of https://api.${random_pet}-${random_id}.local.
cd scripts ./network-tests.sh
- The Uri will be in the form of https://api.${random_pet}-${random_id}.local.
- Skaffold is also set for port-forwading so the service can be accessible over localhost as well
- Workload identity deployment
- Developer namespace with OSM enabled
- Update for Web Application Routing
- Update Documentation and examples
- There is a current issue with Web Application Routing when using a custom Service Account