Cloud and Security Tutorials for .NET: Azure, AWS, GCP

Last updated: October 19, 2026

Every cloud, infrastructure and security article on this site for .NET developers: Azure, AWS and Google Cloud services from C#, serverless, infrastructure as code, and securing the code and the pipeline. These tutorials have not been re-run on .NET 10 yet; check SDK versions before you copy code. Deploying an ASP.NET Core app (Docker, App Service, AKS, GitHub Actions) lives in the ASP.NET Core guide.

Start here

Your situationRead this
Choosing a cloud for a .NET teamAWS vs Azure vs GCP for .NET
Choosing a serverless platform for C#Azure Functions vs AWS Lambda
Storing uploaded filesAzure Blob Storage (or S3, section 2)
Queues and publish/subscribe between servicesAzure Service Bus (or Pub/Sub, section 3)
“Your default credentials were not found” with PUBSUB_EMULATOR_HOST set, or Pub/Sub messages missing after the app exitsGoogle Cloud Pub/Sub with C#
Infrastructure as code in C# instead of YAML or HCLPulumi for .NET
Keeping secrets out of config files and source controlCloud security best practices

1. Pick a cloud and run code serverless

2. Store data and files

  • Azure Blob Storage: managed identity, upload from ASP.NET Core, streaming downloads, listing, metadata and SAS URLs.
  • AWS S3: uploads, multipart with TransferUtility, paginated listing, presigned URLs and the SDK v4 null-collection pitfall.
  • Azure Cosmos DB: partition keys, CRUD and error handling, LINQ queries, continuation tokens, ETags, transactional batch and change feed.
  • AWS DynamoDB: the three SDK programming models, mapping a C# class, CRUD, query vs scan and DynamoDB Local.

3. Messaging between services

  • Azure Service Bus: one shared client, sending in batches, processing messages, topics and dead-letter queues.
  • Google Cloud Pub/Sub: publish and subscribe from C# against the local emulator, hosting in a Worker Service, ordering, filters and dead-letter topics, plus the EmulatorDetection and shutdown traps that lose messages. (tested on .NET 10)

4. Infrastructure as code

Pulumi and the AWS CDK let you write infrastructure in C#; Terraform is the tool most job ads ask for.

  • Pulumi for .NET: how Pulumi works, Output<T>, config and secrets, component resources, unit tests and Pulumi vs Terraform.
  • Terraform for .NET developers: deploying ASP.NET Core to App Service, the same workflow on AWS, state, CI/CD and Terraform vs Bicep vs CloudFormation.
  • AWS CDK and CloudFormation in C#: a first CDK stack, managing stacks with the AWS SDK, removal policies and CDK vs raw templates.

5. Secure the code, the pipeline and the cloud

Code-level topics (SQL injection, password hashing, encryption) are in the C# guide.

  • Cloud security best practices: least privilege, Key Vault, Secrets Manager and Secret Manager from C#, encryption, private endpoints and a checklist.
  • DevSecOps for .NET: SAST in the build, dependency scanning, secret detection, container scanning and a secure pipeline step by step.
  • Zero trust security: the principles, the building blocks and implementing them in ASP.NET Core, including service-to-service calls.
  • Prevent data breaches: a 10-point checklist for developers: secrets, queries, passwords, authorization, input, encryption and logging.
  • Ransomware protection for developers: safe file uploads, no shell commands from input, encryption at rest, integrity monitoring, backups and deserialization.
  • Cybersecurity career roadmap: the security roles that suit developers and a four-phase plan over 12 to 18 months.

Related guides

Calling AI services from these clouds? See the AI in .NET guide.