Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resource order restrictions? #76

Closed
embario opened this issue Apr 2, 2014 · 2 comments
Closed

Resource order restrictions? #76

embario opened this issue Apr 2, 2014 · 2 comments
Labels
bug Something isn't working

Comments

@embario
Copy link

embario commented Apr 2, 2014

Hi there,

I'm bootstrapping a VM with a precise32 box that will contain a django 1.6.2 project that's wrapped by virtualenv and running on gunicorn. I do this using Vagrant to boostrap the VM and then puppet to provision it with this module.

However, I'm getting the following error:

err: /Stage[main]//Python::Gunicorn[vhost]/File[/etc/gunicorn.d/vhost]/ensure: change from absent to present failed: Could not set 'present on ensure: No such file or directory - /etc/gunicorn.d/vhost.puppettmp_7493 at /tmp/vagrant-puppet-1/modules-0/python/manifests/gunicorn.pp:74
notice: /Stage[main]//Python::Requirements[/vagrant/project/requirements.txt]/File[/vagrant/project/requirements.txt]/content: audit change: newly-recorded value {md5}360d2304abc12e709a8c4bbbaf202434
err: /Stage[main]//Python::Virtualenv[/vagrant/project]/Exec[python_virtualenv_/vagrant/project]/returns: change from notrun to 0 failed: sh: 1: virtualenv: not found
sh: 1: /vagrant/project/bin/pip: not found
sh: 1: /vagrant/project/bin/pip: not found

Here is my manifest:

# --- Setup Python, VirtualEnv, Django, and Gunicorn -----------------------------------------------------------------
class { "python":
  version   => "2.7",
  dev       => "true",
  virtualenv  => "true",
  gunicorn    => "true",
  pip         => "true",
}

python::virtualenv { "/vagrant/project":
  ensure  => "present",
  version => "2.7",
  requirements => "/vagrant/project/requirements.txt",
  systempkgs => "true",
  owner => "vagrant",
  group => "vagrant"
}

python::requirements { "/vagrant/project/requirements.txt":
  virtualenv => "/vagrant/project",
  owner => "vagrant",
  group => "vagrant",
}

python::gunicorn { "vhost":
  ensure => "present",
  virtualenv => "/vagrant/project",
  mode       => "wsgi",
  dir        => "/vagrant/project",
  bind        => "unix:/tmp/gunicorn.socket",
  template    => "python/gunicorn.erb"
}

Not really sure what I'm doing wrong here. Any ideas?

@shivapoudel
Copy link
Contributor

Hum, looks like we have to look after..

@shivapoudel
Copy link
Contributor

Close in lack of user feedback.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants