EXPERIMENT 1 (Vagrant) - Solution
EXPERIMENT 1 (Vagrant) - Solution
This exercise will guide them through setting up a virtual environment using
Vagrant, configuring the environment via a Vagrantfile, and managing the
virtual machines (VMs) with basic Vagrant commands.
Objective:
Prerequisites:
Install Vagrant:
vagrant --version
mkdir vagrant_lab
cd vagrant_lab
Initialize Vagrant:
vagrant init
Vagrant.configure("2") do |config|
end
end
vagrant up
Vagrant will download the specified box (if not already downloaded) and
launch the VM.
• SSH into the VM:
• Connect to the running VM using SSH:
vagrant ssh
vagrant halt
vagrant destroy
This will remove all traces of the VM, including any data stored on it.
Submission: