CentOS 7.x is required, this won’t work older versions.
First, enable the dotnet repository for yum:
yum install centos-release-dotnet
Next, install the runtime package:
yum info rh-dontnet20 rh-dotnet20-runtime
The following packages will be installed:
Installing for dependencies:
Install 1 Package (+7 Dependent packages)
Total download size: 54 M
Installed size: 175 M
And that’s it! The .net core 2.0 runtime is installed in /opt/rh/rh-dotnet20
# /opt/rh/rh-dotnet20/root/bin/dotnet --version
Kestrel hosted asp.net apps can be served, preferably thru a reverse proxy server if the service is to be exposed to the public. Microsoft has instructions on how to setup apache + kestrel or Kestrel + NGINX, both with systemd monitoring for the Kestrel microservice.