Skip to content

puppet tries to create vhost before nginx is installed? #610

@tgallant

Description

@tgallant

puppet file:

Exec { path => [ "/bin/", "/sbin/" , "/usr/bin/", "/usr/sbin/" ] }

class {'nginx': }

nginx::resource::vhost { 'static-app':
  www_root => '/app',
}
Vagrant: 1.7.2
Puppet: 3.7.4
puppet-nginx(and dependencies): pulled from master branch on github

I am a puppet noob and I'm having a hard time figuring this out.

I am using vagrant with puppet as the provisioner. When I run vagrant up, it goes through the steps but always fails at:

Error: Could not set 'file' on ensure: No such file or directory - /etc/nginx/sites-available/static-app.conf20150420-1811-gd4k2p.lock

From my googling it seems that this error is caused when the parent directory doesn't exist.

a few lines after the error I get this:

 ==> default: Notice: /Stage[main]/Nginx::Config/File[/etc/nginx/nginx.conf]/content: content changed '{md5}f7984934bd6cab883e1f33d5129834bb' to '{md5}c56373a1bb1120304dbba46e017b22a6'
==> default: Notice: /Stage[main]/Nginx::Config/File[/etc/nginx/conf.mail.d]/ensure: created
==> default: Notice: /Stage[main]/Nginx::Config/File[/etc/nginx/sites-enabled]/ensure: created

Looks to me that the vhost is being created before the nginx directory.

am i doing something wrong here?

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingneeds-feedbackFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions