【问题标题】:PuPHPet Vagrant configuration doesn't sync with the good folderPuPHPet Vagrant 配置与好文件夹不同步
【发布时间】:2015-08-21 17:34:00
【问题描述】:

我是 vagrant 的新手,所以我尝试使用 puphpet 来配置我的虚拟机

但我不明白为什么我的文件夹不与我的 VM 的 /var/www 同步。 但是我看到当我在我的 VM 的 /vagrant 文件夹中更新或更改我的文件夹机器中的某些内容时是同步的。

你能告诉我如何在我的虚拟机中同步 /var/www/html 之类的 /vagrant 吗?

这是我用于同步文件夹的 puphpet 的 config.yml:

synced_folder:
            vflsf_mny3nbub9zel:
                source: ./
                target: /var/www
                sync_type: rsync
                smb:
                    smb_host: ''
                    smb_username: ''
                    smb_password: ''
                rsync:
                    args:
                        - '--verbose'
                        - '--archive'
                        - '-z'
                    exclude:
                        - .vagrant/
                        - .git/
                    auto: 'true'
                owner: www-data
                group: www-data

非常感谢,对不起我的英语:/

【问题讨论】:

    标签: vagrant rsync


    【解决方案1】:

    在 Vagrantfile 所在的主机中尝试以下操作(由 config.yaml 中的“源”表示)
    $ vagrant rsync-auto

    这会将添加/更改的文件从主机同步到来宾虚拟机。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2016-02-08
      • 2016-09-08
      • 2017-01-01
      • 2016-06-18
      • 2016-03-21
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多