Installation with Vagrant

Table of contents

  1. Set environment files
  2. Working with Vagrant
    1. Run the VM
    2. Accessing the VM
    3. Provision the VM
    4. See VM status
    5. Halt the VM
    6. Destroy the VM

Required Vagrant, Ansible and VirtualBox installation

You need to have Vagrant, Ansible and VirtualBox installed on the machine where you want to deploy uvlhub

Only for a development environment

This manual is intended for a development environment. For a production environment, visit Deployment.

Set environment files

First, copy the .env.vagrant.example file to the .env file that will be used to set the environment variables.

cp .env.vagrant.example .env

Working with Vagrant

vagrant folder

All Vagrant commands must be executed inside the vagrant folder located in the root of the project.

cd vagrant

Run the VM

To start the virtual machine in development mode, use the Vagrantfile located in vagrant folder. The command will set up and run the VM.

vagrant up

If everything worked correctly, you should see the deployed version of uvlhub in development at http://localhost:5000

Accessing the VM

To access the VM and execute operations from within (such as rosemary), run:

vagrant ssh

This will switch to the internal MV console. To exit, run:

exit

Provision the VM

If you need to run the provisioning scripts again (*.yml) (e.g., after making changes to them), use the following command:

vagrant up --provision

See VM status

To verify that the virtual machine is running correctly, use the following command:

vagrant status

Halt the VM

To halt (stop) the virtual machine, use the following command:

vagrant halt

Destroy the VM

To destroy the virtual machine (removing all data), use the following command:

vagrant destroy

Following these steps, you should be able to set up, run, and manage your Vagrant virtual machine efficiently.