Angelo
Angelo
I am Angelo. A systems engineer passionate about Linux and all open-source software. Although here I'm just another member of the family.

How to install Dotnet in Rocky Linux 8 / Alma Linux 8

- Advertisement -

Hello, friends. In this post, you will learn how to install Dotnet on Rocky Linux 8 / Alma Linux 8 Let’s get to it.

What is Dotnet?

Microsoft .NET is an application development and execution platform. This means that it not only provides all the tools and services needed to develop modern enterprise applications. .NET offers a managed application runtime environment, programming languages and compilers, and allows the development of all kinds of functionalities.

Best of all, it can be installed on Linux in a matter of minutes. In this sense, we live in an era where Linux is already considered by Microsoft, and we can already have some of its programs on Linux.

The learning curve is low, so in a short time we will be able to do wonders.

The installation is also easy, you’ll see.

Install Dotnet on Rocky Linux 8 / Alma Linux 8

Fortunately, DotNet is included in the official repositories of the distribution. So, we can quickly install it.

First, make sure that the system is fully up-to-date

sudo dnf update

After that just run

sudo dnf install dotnet
1.- Install DotNet on Rocky Linux 8 / Alma Linux 8
1.- Install DotNet on Rocky Linux 8 / Alma Linux 8
- Advertisement -

This will install the whole package including the tools, the runtime and the SDK.

But it is also possible to just install the Runtime with the command

sudo dnf install dotnet-runtime-6.0

Or the SDK:

sudo dnf install dotnet-sdk-6.0

You can then check the installed version by running

dotenet --info
2.- DotNet info
2.- DotNet info

Testing the installation

To find out if everything went well, we need to test DotNet with a simple application.

This can be done like this

dotnet new console -o Example -f net6.0

Replace Example with the name of your project.

Access the new application’s folder

cd Example

Since it is a Console application, it comes with a built-in example. Run it like this.

dotnet run
3.- Using DotNet
3.- Using DotNet

This way, we will know that DotNet is installed correctly, and we will be able to use it.

Conclusion

In this post, you learned how to install DotNet on Rocky Linux 8 / Alma Linux 8 effortlessly. Thanks for reading.

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Latest articles

Join us on Facebook

x