summaryrefslogtreecommitdiff
path: root/manifests/install.pp
diff options
context:
space:
mode:
authorSergey Stankevich <sergey.stankevich@gmail.com>2012-09-09 18:36:30 -0400
committerSergey Stankevich <sergey.stankevich@gmail.com>2012-09-09 18:36:30 -0400
commited137893babebabdfdb5adf44d1a52272093ce8b (patch)
treef611108dc849fe8f4372aac981d7e242d59b957b /manifests/install.pp
Initial import
Diffstat (limited to 'manifests/install.pp')
-rw-r--r--manifests/install.pp31
1 files changed, 31 insertions, 0 deletions
diff --git a/manifests/install.pp b/manifests/install.pp
new file mode 100644
index 0000000..dec99b8
--- /dev/null
+++ b/manifests/install.pp
@@ -0,0 +1,31 @@
+class python::install {
+
+ $python = $python::version ? {
+ 'system' => 'python',
+ default => "python${python::version}",
+ }
+
+ package { $python: ensure => present }
+
+ $dev_ensure = $python::dev ? {
+ true => present,
+ default => absent,
+ }
+
+ package { "${python}-dev": ensure => $dev_ensure }
+
+ $venv_ensure = $python::virtualenv ? {
+ true => present,
+ default => absent,
+ }
+
+ package { 'python-virtualenv': ensure => $venv_ensure }
+
+ $gunicorn_ensure = $python::gunicorn ? {
+ true => present,
+ default => absent,
+ }
+
+ package { 'gunicorn': ensure => $gunicorn_ensure }
+
+}