1

I have recently installed vagrant and red hat in windows 8 environment. I want to use my projects in windows drive in redhat running on vagrant machines. Is there a mechanism to copy paste or access project folders already present in windows environment inside vagrant virtual machines. I am running on Windows 8 with Red Hat 7 as the guest OS for Vagrant.

2
  • Just to clarify, you're running on Windows with Red Hat as the guest OS for your Vagrant box?
    – admin
    Commented Oct 4, 2018 at 7:50
  • yes......................
    – ss321c
    Commented Oct 4, 2018 at 11:12

1 Answer 1

1

Synced folders basic usage, on your Vagrantfile look for (this will be commented out by default and you can use it by removing the # sign):

Vagrant.configure("2") do |config|
  # other config here

  config.vm.synced_folder "shared/", "/home/vagrant/shared"
end

The "shared" folder is within the same folder as your Vagrantfile

red-hat -
        - shared/
        - Vagrantfile

The "/home/vagrant/shared" folder will be the directory which is within the Red Hat box, all your files inside will be synced to and from the Windows folder. You can also move this shared folder for the box elsewhere i.e "/srv/website".

Vagrant Synced Folders Basic Usage

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .