Skip to content
Switch branches/tags

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time

ASP.NET Core Docker Container Sample for DigitalOcean App Platform

Deploy to DigitalOcean

This sample demonstrates how to run a containerized ASP.NET Core application on DigitalOcean App Platform. Since App Platform doesn't yet support dotnet core, this sample shows how to accomplish this using Dockerfile.

This sample has been adapted from official dotnet docker sample -

Getting Started

These steps will get this sample application running for you using DigitalOcean.

Note: Following these steps will result in charges for the use of DigitalOcean services


  • You need a DigitalOcean account. If you don't already have one, you can sign up using the link below and receive a $100, 60-day credit to get started.

DigitalOcean Referral Badge

Forking the Sample App Source Code

To use all the features of App Platform, you need to be running against your own copy of this application. To make a copy, click the Fork button above and follow the on-screen instructions. In this case, you'll be forking this repo as a starting point for your own app (see Github documentation to learn more about forking repos.

After forking the repo, you should now be viewing this README in your own github org (e.g.<your-org>/aspnetcoresample)

Note: You can skip forking this repo and select a sample app from the app creation page, however do notice that certain features will be disabled.

Deploying the App

  1. Visit (if you're not logged in, you may see an error message. Visit directly and authenticate, then try again)
  2. Click "Launch App" or "Create App"
  3. Choose GitHub and authenticate with your GitHub credentials.
  4. Under Repository, choose this repository (e.g. <your-org>/aspnetcoresample)
  5. On the next two screens, leave all the defaults unchanged.
  6. Click "Launch App"
  7. You should see a "Building..." progress indicator. And you can click "Deployments"→"Details" to see more details of the build.
  8. It can currently take 5-6 minutes to build this app, so please be patient. Live build logs are coming soon to provide much more feedback during deployments.
  9. Once the build completes successfully, click the "Live App" link in the header and you should see your running application in a new tab

Making Changes to Your App

As long as you left the default Autodeploy option enabled when you first launched this app, you can now make code changes and see them automatically reflected in your live application. During these automatic deployments, your application will never pause or stop serving request because the App Platform offers zero-downtime deployments.

Learn More

You can learn more about the App Platform and how to manage and update your application at

Deleting the App

When you no longer need this sample application running live, you can delete it by following these steps:

  1. Visit the Apps control panel at
  2. Navigate to the sample-dockerfile app
  3. Choose "Settings"->"Destroy"

This will delete the app and destroy any underlying DigitalOcean resources

Note: If you don't delete your app, charges for the use of DigitalOcean services will continue to accrue.