Example #1
0
 def create_group(self, group):
     if group:
         with fabset(warn_only=True):
             run(env.facts.sudo + 'groupadd ' + group)
Example #2
0
 def packager(self):
     if self._packager is None:
         with fabset(warn_only=True):
             result = run('rpm -v')
         self._packager = 'deb' if result.failed else 'rpm'
     return self._packager
Example #3
0
 def create_user(self, user):
     if user:
         with fabset(warn_only=True):
             run(env.facts.sudo + 'useradd ' + user)
Example #4
0
 def uwsgi(self):
     package.install('python-dev', 'libxml2-dev')
     module.install('uwsgi')
     action.render('uwsgi.conf', '/etc/init/uwsgi.conf')
     with fabset(warn_only=True):
         run(env.facts.sudo + 'service uwsgi start')
Example #5
0
 def create_group(self, group):
     if group:
         with fabset(warn_only=True):
             run(env.facts.sudo + 'groupadd ' + group)
Example #6
0
 def create_user(self, user):
     if user:
         with fabset(warn_only=True):
             run(env.facts.sudo + 'useradd ' + user)
Example #7
0
 def packager(self):
     if self._packager is None:
         with fabset(warn_only=True):
             result = run('rpm -v')
         self._packager = 'deb' if result.failed else 'rpm'
     return self._packager
Example #8
0
 def uwsgi(self):
     package.install('python-dev', 'libxml2-dev')
     module.install('uwsgi')
     action.render('uwsgi.conf', '/etc/init/uwsgi.conf')
     with fabset(warn_only=True):
         run(env.facts.sudo + 'service uwsgi start')