DEV Community

Alan
Alan

Posted on • Updated on

NodeJS virtual environment in Fedora Toolbox

Fedora Toolbox is used to create isolated development environment with container technologies(podman).

Why Fedora Toolbox
1.It is tailor made and built-in fedora.
2.By utilizing a Fedora base image, it can install cross language and dependencies environment.
3.As Toolbox is mutable environment and docker environment is immutable; Docker is usually for software deployment and this is for software development

Hands-on Example

So let's start with creating nodeJS development environment inside Fedora.

toolbox create node
toolbox enter node
sudo dnf install nodejs

# Install Yarn
curl --silent --location https://dl.yarnpkg.com/rpm/yarn.repo | sudo tee /etc/yum.repos.d/yarn.repo
sudo dnf install yarn
Enter fullscreen mode Exit fullscreen mode

Output for Fedora Toolbox

  1. Create a fedora container, named node
Created Container: Node
# ... Other logs downloading and setting up container

Enter fullscreen mode Exit fullscreen mode

Dump Screen for create environment

  1. Entering virtual environment Environment name changed from fedora to toolbox

Manage Environemnts | Containers

  1. List Containers
toolbox list
Enter fullscreen mode Exit fullscreen mode

Containers Detail

  1. Remove Containers
toolbox rm node
# No Output for this Command
Enter fullscreen mode Exit fullscreen mode

Reference

To understand the container technology behind Fedora toolbox, you can visit this essay

Top comments (0)