How to Set up a Raspberry Pi: Creating a .Net Core Website on Your Pi
Be sure to check out the whole Raspberry Pi series:
  1. How to Set up a Raspberry Pi: Getting Started
  2. How to Set up a Raspberry Pi: Enabling SSH on Raspberry Pi
  3. How to Set up a Raspberry Pi: Troubleshooting Issues
  4. How to Set up a Raspberry Pi: Creating a .Net Core Website on Your Pi
  5. How to Set up a Raspberry Pi: Set up Build to Raspberry Pi Using Azure DevOps
  6. How to Set up a Raspberry Pi: Set up Release Pipeline to Raspberry Pi
Most websites that run on-premise production servers require a lot of hardware. If all you need is a dev site or something local that you want to tinker with, then a Raspberry Pi works just fine. In my case, I know this is only a local website. Also, there is only me and maybe one other person that will be able to access it. It’s also really good for creating an app with familiar web programming languages. Whatever your case, this is what I had to do to set up my very own website on the Raspberry Pi.

Keep in mind I don’t go through any DNS settings to make this available to the outside world since I only wanted mine available locally. There are no security concerns that I addressed here either, so you may have to customize what I did to enable that.
  1. Download .NET Core SDK. Go to here to do that (This blog post came out when 3.1 was the latest stable release). 
  2. You want to download the ARM32 version. As a side note, the Raspberry Pi 4 is technically a 64-bit architecture. However, the latest version of Debian runs on 32-bit OS, so you still need the 32-bit version. You only need ARM64 if you are running full Ubuntu on your Pi.location of ARM32 version download
  3. This will direct you to the navigation page. Next, change the directory to Downloads by opening the terminal window and typing, cd Downloads
  4. To get the install script, scroll down on the browser you downloaded .NET from, and copy/paste the script into a terminal window. copy/paste the script into a terminal window
  5. Press Enter to run the last command.
  6. It doesn’t automatically make dotnet a global command, so you have to add that to Linux’s version of your PATH. To do this, open up .bashrc by typing, less ~/.bashrc.
  7. Type, v.
  8. Scroll down to the end of the file.
  9. Type, export PATH=$PATH:$HOME/dotnet.
  10. cntrl+X to exit.
  11. Y to save.
  12. Enter to confirm.
  13. Q to quit less.
  14. Close and reopen your terminal
  15. Type in, dotnet --version Type in dotnet --version example
  16. If it displays the latest version of dotnet, then you were successful! Now on to actually making your website!
Making your own website locally is one of the coolest ways to test your deployments and to tinker with your own development skills. Other people might think that you know a lot of stuff if you can show this off. So with that, I say, show off your brand new site with pride.

weightlifting gif

Be sure to check out the whole Raspberry Pi series:
  1. How to Set up a Raspberry Pi: Getting Started
  2. How to Set up a Raspberry Pi: Enabling SSH on Raspberry Pi
  3. How to Set up a Raspberry Pi: Troubleshooting Issues
  4. How to Set up a Raspberry Pi: Creating a .Net Core Website on Your Pi
  5. How to Set up a Raspberry Pi: Set up Build to Raspberry Pi Using Azure DevOps
  6. How to Set up a Raspberry Pi: Set up Release Pipeline to Raspberry Pi

Share This Post:

Twitter Pinterest Facebook Google+
Click here to read more posts
Start a Project with Us
Photo of the author, Albert Hovingh

About the author

A Grand Valley State University graduate, Albert is the guy who takes on new technology and learns it inside and out. At BizStream, he mostly does SharePoint and Kentico development, but you can put him on any project and it will be a success. Albert has four adorable kids, and is a shark when it comes to Foosball and anything XBox-related.

View other posts by Albert

Subscribe to Updates

Stay up to date on what BizStream is doing and keep in the loop on the latest with Kentico.