diff --git a/puppet/modules/colab/manifests/init.pp b/puppet/modules/colab/manifests/init.pp index f2146b9..0200790 100644 --- a/puppet/modules/colab/manifests/init.pp +++ b/puppet/modules/colab/manifests/init.pp @@ -1,90 +1,39 @@ class colab { - # Common - include apt - include ps1 - include vim - include ntp - include locale - include timezone - include postfix - include supervisor - include colab::requirements - include colab::cronjobs - - apt::ppa { 'ppa:nginx/stable': } + require pip - class { 'nginx': - require => Apt::Ppa['ppa:nginx/stable'], - } - - Mailalias { - notify => Exec['newaliases'], - require => Class['postfix'], - } - - exec { 'newaliases': - command => 'sendmail -bi', - path => '/usr/sbin', - refreshonly => true, - } + include appdeploy::deps::lxml + include appdeploy::deps::postgresql + include colab::cronjobs - group { 'colab': - ensure => present, - } + appdeploy::django { 'colab': + user => 'colab', + directory => '/home/colab/colab/src', + proxy_hosts => [ + 'colab.interlegis.leg.br', + ], - user { 'colab': - ensure => present, - managehome => true, - shell => '/bin/bash', - gid => 'colab', - groups => ['sudo'], } - mailalias { 'colab': - ensure => present, - recipient => 'root', - } + ensure_packages(['mercurial', 'openjdk-7-jre', 'memcached', 'sshfs']) - file { 'colab-sudoers': - ensure => present, - path => '/etc/sudoers.d/colab-sudoers', - source => 'puppet:///modules/colab/colab-sudoers', - mode => '0440', - owner => root, - group => root, + # XMPP connection manager + package { 'punjab': + ensure => installed, + provider => pip, } - file { 'root-ssh-dir': - ensure => directory, - mode => '0700', - path => '/root/.ssh', + # Punjab dep + package { 'Twisted': + ensure => installed, + provider => pip, } - # Should generate instead of copying - #file { 'root-ssh-private-key': - # ensure => present, - # mode => '0600', - # path => '/root/.ssh/id_rsa', - # source => 'puppet:///modules/colab/root_id_rsa', - # owner => root, - # group => root, - #} - - #file { 'root-ssh-public-key': - # ensure => present, - # mode => '0644', - # path => '/root/.ssh/id_rsa.pub', - # source => 'puppet:///modules/colab/root_id_rsa.pub', - # owner => root, - # group => root, - #} - - supervisor::app { 'colab': - command => '/home/colab/.virtualenvs/colab/bin/gunicorn colab.wsgi:application -c colab/gunicorn.conf.py', - directory => '/home/colab/colab/src/', - user => 'colab', + # Punjab dep + package { 'pyOpenSSL': + ensure => installed, + provider => pip, } supervisor::app { 'punjab': @@ -98,12 +47,4 @@ class colab { directory => '/home/colab/apache-solr-3.6.2/example', user => 'colab', } - - nginx::config { 'nginx': - content => template('colab/nginx/extra_conf.erb'), - } - - nginx::site { '000-colab': - content => template('colab/nginx/site_default.erb'), - } } -- libgit2 0.21.2