1

我刚刚用 puphpet 创建了一个非常简单的配置。它包括一个 nginx 和一个 hhvm 和一个 mysql。还没有别的。当我开始运行 vagrant up 时,它每次都会失败并显示相同的消息。

这是输出:

vagrant up
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Importing base box 'puphpet/ubuntu1404-x64'...
==> default: Matching MAC address for NAT networking...
==> default: Checking if box 'puphpet/ubuntu1404-x64' is up to date...
==> default: Setting the name of the VM: vagrant-hhvm_default_1441131243385_35080
==> default: Clearing any previously set network interfaces...
==> default: Preparing network interfaces based on configuration...
    default: Adapter 1: nat
    default: Adapter 2: hostonly
==> default: Forwarding ports...
    default: 22 => 6632 (adapter 1)
    default: 22 => 2222 (adapter 1)
==> default: Running 'pre-boot' VM customizations...
==> default: Booting VM...
==> default: Waiting for machine to boot. This may take a few minutes...
    default: SSH address: 127.0.0.1:2222
    default: SSH username: vagrant
    default: SSH auth method: private key
    default: Warning: Connection timeout. Retrying...
    default:
    default: Vagrant insecure key detected. Vagrant will automatically replace
    default: this with a newly generated keypair for better security.
    default:
    default: Inserting generated public key within guest...
    default: Removing insecure key from the guest if its present...
    default: Key inserted! Disconnecting and reconnecting using new SSH key...
==> default: Machine booted and ready!
==> default: Checking for guest additions in VM...
==> default: Checking for host entries
==> default: adding to (/etc/hosts) : 192.168.56.101  local.puphpet  # VAGRANT: 88884799495109854333bebc73976cae (default) / b08f4c50-86e3-4307-94f2-0175fcee553e
==> default: Setting hostname...
==> default: Configuring and enabling network interfaces...
==> default: Installing NFS client...
==> default: Exporting NFS shared folders...
==> default: Preparing to edit /etc/exports. Administrator privileges will be required...
The nfsd service does not appear to be running.
Starting the nfsd service
==> default: Mounting NFS shared folders...
==> default: Mounting shared folders...
    default: /vagrant => /Users/emul/vagrant-hhvm
    default: /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f => /Users/emul/vagrant-hhvm/puphpet/puppet/modules
    default: /tmp/vagrant-puppet/manifests-893fcda21077f5a583c2dbbba8515c0a => /Users/emul/vagrant-hhvm/puphpet/puppet
==> default: Running provisioner: shell...
    default: Running: inline script
==> default: stdin: is not a tty
==> default: Running provisioner: shell...
    default: Running: /var/folders/s9/n6ctw0bs41gdk8qwd9_gv0dh0000gn/T/vagrant-shell20150901-17569-996glt.sh
==> default: stdin: is not a tty
==> default:
==> default:  ____        ____  _   _ ____      _      generated using
==> default: |  _ \ _   _|  _ \| | | |  _ \ ___| |_   ___ ___  _ __ ___
==> default: | |_) | | | | |_) | |_| | |_) / _ \ __| / __/ _ \| '_ ` _ \
==> default: |  __/| |_| |  __/|  _  |  __/  __/ |_ | (_| (_) | | | | | |
==> default: |_|    \__,_|_|   |_| |_|_|   \___|\__(_)___\___/|_| |_| |_|
==> default: Running initial-setup apt-get update
==> default: Finished running initial-setup apt-get update
==> default: Running provisioner: shell...
    default: Running: /var/folders/s9/n6ctw0bs41gdk8qwd9_gv0dh0000gn/T/vagrant-shell20150901-17569-1uw0u3y.sh
==> default: stdin: is not a tty
==> default: Generating public/private rsa key pair.
==> default: Your identification has been saved in /vagrant/puphpet/files/dot/ssh/root_id_rsa.
==> default: Your public key has been saved in /vagrant/puphpet/files/dot/ssh/root_id_rsa.pub.
==> default: The key fingerprint is:
==> default: 43:bc:72:31:8c:6a:dc:cb:df:e4:4a:7f:38:a9:a5:a5 root@local
==> default: The key's randomart image is:
==> default: +--[ RSA 2048]----+
==> default: |                 |
==> default: |       +         |
==> default: |      . *        |
==> default: |   . o . +       |
==> default: |    + o S        |
==> default: |   . . + .       |
==> default: |      o . +o     |
==> default: |       o X+ .    |
==> default: |        Eo+o     |
==> default: +-----------------+
==> default: dpkg-preconfigure: unable to re-open stdin: No such file or directory
==> default: Your private key for SSH-based authentication has been saved to 'puphpet/files/dot/ssh/root_id_rsa'!
==> default: Generating public/private rsa key pair.
==> default: Your identification has been saved in /vagrant/puphpet/files/dot/ssh/id_rsa.
==> default: Your public key has been saved in /vagrant/puphpet/files/dot/ssh/id_rsa.pub.
==> default: The key fingerprint is:
==> default: a8:6b:13:2c:9b:02:37:05:ec:61:2e:dc:ca:2c:ef:9a root@local
==> default: The key's randomart image is:
==> default: +--[ RSA 2048]----+
==> default: | .               |
==> default: |  =              |
==> default: |.+.o             |
==> default: |..o..  .         |
==> default: |o..o  . S        |
==> default: |o++ o.           |
==> default: |oo =..           |
==> default: |..+ o.           |
==> default: |E+....           |
==> default: +-----------------+
==> default: Your private key for SSH-based authentication has been saved to 'puphpet/files/dot/ssh/id_rsa'!
==> default: Adding generated root key to /root/.ssh/id_rsa
==> default: Adding generated root key to /root/.ssh/id_rsa.pub
==> default: Adding generated root key to /root/.ssh/authorized_keys
==> default: Adding generated key to /home/vagrant/.ssh/id_rsa
==> default: Adding generated key to /home/vagrant/.ssh/id_rsa.pub
==> default: Adding generated key to /home/vagrant/.ssh/authorized_keys
==> default: Running provisioner: shell...
    default: Running: /var/folders/s9/n6ctw0bs41gdk8qwd9_gv0dh0000gn/T/vagrant-shell20150901-17569-18e0m4w.sh
==> default: stdin: is not a tty
==> default: Running provisioner: shell...
    default: Running: /var/folders/s9/n6ctw0bs41gdk8qwd9_gv0dh0000gn/T/vagrant-shell20150901-17569-gk5ewj.sh
==> default: stdin: is not a tty
==> default: Running provisioner: shell...
    default: Running: /var/folders/s9/n6ctw0bs41gdk8qwd9_gv0dh0000gn/T/vagrant-shell20150901-17569-14ore9c.sh
==> default: stdin: is not a tty
==> default: Successfully installed deep_merge-1.0.1
==> default: 1 gem installed
==> default: Successfully installed thread_safe-0.3.5
==> default: Successfully installed minitest-5.8.0
==> default: Successfully installed tzinfo-1.2.2
==> default: Successfully installed i18n-0.7.0
==> default: Successfully installed activesupport-4.2.4
==> default: 5 gems installed
==> default: Successfully installed vine-0.2
==> default: 1 gem installed
==> default: Running provisioner: puppet...
==> default: Running Puppet with site.pp...
==> default: stdin: is not a tty
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/apt/lib/facter/apt_update_last_success.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/apt/lib/facter/apt_updates.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/composer/lib/facter/composer_home.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/concat/lib/facter/concat_basedir.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/firewall/lib/facter/ip6tables_version.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/firewall/lib/facter/iptables_persistent_version.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/firewall/lib/facter/iptables_version.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/git/lib/facter/git_exec_path.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/git/lib/facter/git_version.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/java/lib/facter/java_major_version.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/java/lib/facter/java_patch_level.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/java/lib/facter/java_version.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/php/lib/facter/php_fact_extension_dir.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/php/lib/facter/php_fact_version.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/puppi/lib/facter/last_run.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/puppi/lib/facter/puppi_projects.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/puppi/lib/facter/windows_common_appdata.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/rvm/lib/facter/rvm_installed.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/rvm/lib/facter/rvm_version.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/staging/lib/facter/staging_http_get.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/staging/lib/facter/staging_windir.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/stdlib/lib/facter/facter_dot_d.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/stdlib/lib/facter/pe_version.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/stdlib/lib/facter/puppet_vardir.rb
==> default: Info: Loading facts in /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/stdlib/lib/facter/root_home.rb
==> default: Error: "off" is not a boolean.  It looks to be a String at /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/nginx/manifests/resource/location.pp:198 on node local.puphpet
==> default: Error: "off" is not a boolean.  It looks to be a String at /tmp/vagrant-puppet/modules-118aff3d1d14e37133864c5b11fbc99f/nginx/manifests/resource/location.pp:198 on node local.puphpet
The SSH command responded with a non-zero exit status. Vagrant
assumes that this means the command failed. The output for this command
should be in the log above. Please read the output to determine what
went wrong.

虚拟机正在运行,但上面没有可用的东西(nginx、hhvm)。我不知道这是否重要,但我在 MacOS X 10.10 上运行它任何帮助将不胜感激。

4

2 回答 2

7

在您的 puphpet/config.yml 文件中

更改以下所有实例:

autoindex: 'off'
internal: 'off'

至:

autoindex: false
internal: false
于 2015-09-02T11:21:01.693 回答
0

目前遇到了同样的问题,但这条线没有任何问题

198. validate_bool($internal)

这个 var 在上面声明了几行

define nginx::resource::location (
  $ensure               = present,
  $internal             = false,

这个变量的文档是

[ internal ] - 指示此位置是否只能用于内部请求。默认值:假

所以似乎问题出在其他地方

我的设置是 Win8 主机、Vbox、Ubuntu Trusty 14.04 LTS x64、NFS、nginx、PHP 5.6、mysql 5.6

于 2015-09-01T23:17:01.750 回答