Skip to content

cehbrecht/dev-machine

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Ubuntu Vagrant VM for Dev

This is a headless Ubuntu 22.04 VM provisioned with:

  • 8 GB RAM, 2 CPUs, 100 GB dynamic disk
  • Git, Vim, Byobu, Fish shell
  • Miniforge Conda (base environment)
  • Byobu auto-start for SSH sessions
  • Podman + podman-compose for container workflows
  • Fully compatible with Dockerfiles and docker-compose.yml

Setup

  1. Install dependencies on your Mac:

    brew install --cask virtualbox
    brew install vagrant
  2. Clone or create this project folder and place the Vagrantfile inside:

    git clone https://github.com/cehbrecht/dev-machine.git
    cd dev-machine/
  3. Bring up the VM:

    vagrant up
    vagrant ssh
  • Byobu will auto-start.
  • Bash is the default shell; Fish is available (fish).
  • Conda base environment is active.

Using Conda

conda info          # check Conda
conda list          # installed packages
conda create -n dev python=3.11 numpy pandas tqdm
conda activate dev

Using Podman + podman-compose

  • Build images from Dockerfiles:

    podman build -t myimage .

  • Run docker-compose.yml using Podman:

    podman-compose up

  • Manage containers as usual (podman ps, podman stop, etc.)


VS Code Remote-SSH Workflow

  1. Install the Remote - SSH extension in VS Code.

  2. Add a new SSH host in ~/.ssh/config:

    Host ubunti HostName 127.0.0.1 User vagrant Port 2222 IdentityFile ~/.vagrant.d/insecure_private_key

  3. In VS Code, choose Remote-SSH → Connect to Host → ubunti.

  4. You can now edit code locally while running inside the VM. Use /vagrant to access your synced folder:

    cd /vagrant


Disk

  • Root filesystem: ~100 GB dynamic disk
  • Plenty of space for Conda envs, datasets, and containers

Tips

  • Shut down VM:

    vagrant halt

  • Restart:

    vagrant up

  • Destroy (reset to clean VM):

    vagrant destroy -f

About

My VM with vagrant for development.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published