Skip to content

BountyHunter1999/ansible-local-test-machine

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 

Repository files navigation

ansible-local-test-machine

Simple Server

Simple Server Setup Simple Server

Windows

  • For the Windows machine without wsl2, I create a separate ansible control machine and work from there

Windows WSL2

  • Install Vagrant on both the Linux machine on WSL and Windows
  • In WSL Linux run: vagrant plugin install virtualbox_WSL2
  • In WSL linux, export these things (I would add them to .bashrc or .zshrc file:
    export VAGRANT_WSL_ENABLE_WINDOWS_ACCESS="1"
    export VAGRANT_WSL_WINDOWS_ACCESS_USER_HOME_PATH="/mnt/c/Users/username/"
    export PATH="$PATH:/mnt/c/Program Files/Oracle/VirtualBox"
  • with this, we can use the ansible

Linux

  • For Linux, vagrant provision with Ansible might be easier
Vagrant.configure("2") do |config|
  config.vm.box = "geerlingguy/rockylinux8"

  # Provisioning configuration for Ansible
  config.vm.provision "ansible" do |ansible|
    ansible.playbook = "playbook.yml"
  end
end

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published