Skip to content

Commit

Permalink
Merge pull request #8 from philspokas/session-7-updates
Browse files Browse the repository at this point in the history
Session 7 updates
  • Loading branch information
philspokas authored Oct 29, 2024
2 parents 220ee22 + d056ef6 commit 596ffc3
Show file tree
Hide file tree
Showing 4 changed files with 113 additions and 28 deletions.
70 changes: 70 additions & 0 deletions exercises/containers.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
# Container Exercises
Create and run containers. Pre-built images and custom built are used

Pre-requisites for local operations
* Docker Desktop

Pre-requisites for deploying containers to Azure
* Azure subscription
* Azure Container Registry is created and available

## Getting Started with Containers
* Follow [Develop with containers](https://docs.docker.com/get-started/introduction/develop-with-containers/)
* Note that an LAMP stack application and tech stack can be run
* Containers created in virtual network
* Data volume for sql data created
* React, Node, php
* Traefik reverse proxy
* Mysql
* After running ```docker compose watch``` note containers running in Docker Desktop
* Run ```docker compose down``` noting containers are shutdown and removed

## Create and deploy .NET Container

### Publish
* Production and SDK images
* "Chiseled" container images contain minimal components

1. Use dotnet publish to build a container image [Step by step](https://learn.microsoft.com/en-us/dotnet/core/docker/introduction?view=vs-2022#building-container-images)
- note container ddetails in Docker Desktop
- review [Docker coommand line options](https://docs.docker.com/reference/cli/docker/container/run/)
1. Use ```docker init``` to generate default Dockerfile and compose.yaml

### Containerize
1. Follow [step by step](https://learn.microsoft.com/en-us/dotnet/core/docker/build-container?view=vs-2022&tabs=windows&pivots=dotnet-8-0) to containerize a .NET appp
- note multi-stage build process using sdk image and runtime image
1. Use ```docker run -it --entrypoint=sh counter-image``` to inspect contents

## Publish App
https://learn.microsoft.com/en-us/dotnet/core/docker/publish-as-container?pivots=dotnet-8-0

## Publish to Azure
1. Push to ACR
https://learn.microsoft.com/en-us/azure/container-registry/container-registry-get-started-docker-cli?tabs=azure-cli

1. Deploy to Azure Container Instance

https://learn.microsoft.com/en-us/azure/container-instances/container-instances-tutorial-prepare-app
1. Deploy to Azure Container App

1. Build pipeline to deploy

## Containerize Coalesce
1. Generate simple widgets app
https://intellitect.github.io/Coalesce/stacks/vue/getting-started.html
1. Use Publish to run in a continer
1. Use Docker init and Docker Compose to add database service container
1. Push to Azure

## AKS w/ Bicep
https://learn.microsoft.com/en-us/azure/aks/learn/quick-kubernetes-deploy-bicep

## AKS w/ Terraform
https://learn.microsoft.com/en-us/azure/aks/learn/quick-kubernetes-deploy-terraform

## Azure Container Apps
https://learn.microsoft.com/en-us/azure/container-apps/quickstart-code-to-cloud?tabs=bash%2Ccsharp&pivots=with-dockerfile

## Multi-container builds
https://docs.docker.com/build/building/multi-platform/
https://devblogs.microsoft.com/dotnet/improving-multiplatform-container-support/
16 changes: 16 additions & 0 deletions exercises/source-collaboration.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Collaborating through source control and work items

### How Microsoft Develops
* Be familiar with Microsoft approach to dev by reviewing [How Microsoft develops with DevOps
]https://learn.microsoft.com/en-us/devops/develop/how-microsoft-develops-devops())

### Work Management Lab
* Verify understanding by working through this Microsoft Learning lab: [Review Work Management](https://microsoftlearning.github.io/AZ400-DesigningandImplementingMicrosoftDevOpsSolutions/Instructions/Labs/AZ400_M01_L01_Agile_Plan_and_Portfolio_Management_with_Azure_Boards.html)

### Branching Styles Learn Module
* Verify understanding and rational for branch styles: [Design and Implement Branch Strategies](https://learn.microsoft.com/en-us/training/modules/manage-git-branches-workflows/)

### Practice exam!
* Take a practice exam to gain an understanding of what will be covered and self-assess your knowledge level [assessment]( https://learn.microsoft.com/en-us/credentials/certifications/exams/az-400/)


21 changes: 21 additions & 0 deletions exercises/tests.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Tests and test results

## Setup
Exercises below will use a Coalesce gnerated app. What the app does is not important it is only used to demonstrate the concepts.

If you already have an application deployed that can be used you can save yourself some time. However, we do want to keep the solution small in order to focus on the testing topic.

## Unit Tests
- Small, fast, cheap to execute
- do not require a deployed environment

1. E

## Integration Tests
Hit api endpoints that exercise

## Functional Tests
Playwright
Executing manual tests with Azure Tests


34 changes: 6 additions & 28 deletions schedule.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,27 +116,6 @@ You can take as many assessments as you'd like.

<details>

1. git
1. local hooks
1. Removing files with BFG
1. Git LFS for files over 50 MB
1. git filter
1. tags
1. shallow clones

1. [Microsoft Recommended Process for Releases](https://learn.microsoft.com/en-us/training/modules/manage-git-branches-workflows/4-explore-git-branch-model-for-continuous-delivery)
1. [GitHub Flow] https://docs.github.com/en/get-started/using-github/github-flow

### Exercises
1. Verify understanding by working through this Microsoft Learning lab: [Review Work Management](https://microsoftlearning.github.io/AZ400-DesigningandImplementingMicrosoftDevOpsSolutions/Instructions/Labs/AZ400_M01_L01_Agile_Plan_and_Portfolio_Management_with_Azure_Boards.html)
1. Verify understanding and rational for branch styles: [Design and Implement Branch Strategies](https://learn.microsoft.com/en-us/training/modules/manage-git-branches-workflows/)

</details>

## Session 4, Source control collaboration<p/>Oct 08, 2024

<details>

1. git merge
1. Git LFS
1. Overview
Expand All @@ -148,10 +127,6 @@ You can take as many assessments as you'd like.
1. git filter-breanch
1. git and Scalar

### Exercises
* Review https://learn.microsoft.com/en-us/devops/develop/how-microsoft-develops-devops
* take a practice exam! https://learn.microsoft.com/en-us/credentials/certifications/exams/az-400/

</details>

## Session 5, Build and release pipelines<p/>Oct 15, 2024
Expand Down Expand Up @@ -181,18 +156,21 @@ You can take as many assessments as you'd like.

</details>

## Session 7, Testing in pipelines<p/>Oct 29, 2024
## Session 7, Containers and Testing in pipelines<p/>Oct 29, 2024

<b><i>draft</i></b>

1. Containers 101
1. Container Exercises

## Session 8, Package management<p/>Oct 22, 2024

1. test pyramid
1. running unit tests
1. integration tests
1. end to end tests
1. Zaproxy

## Session 8, Package management<p/>Oct 22, 2024

## Session 9, Infrastructure as Code<p/>Nov 12, 2024

## Session 10, Security and compliance<p/>Nov 19, 2024
Expand Down

0 comments on commit 596ffc3

Please sign in to comment.