Hashar has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/312313

Change subject: contint: create /srv based directory hierarchy
......................................................................

contint: create /srv based directory hierarchy

Recreate a file hierachy under /srv:

├── home/
│   └── jenkins-deploy/
│       └── .gitconfig
└── jenkins/
    ├── cache/
    └── workspace/

Change-Id: I674b49581b5ee388cc2b69329041f9d08e4c72e9
---
M modules/role/manifests/ci/slave/labs/common.pp
1 file changed, 55 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/13/312313/1

diff --git a/modules/role/manifests/ci/slave/labs/common.pp 
b/modules/role/manifests/ci/slave/labs/common.pp
index 4784c40..275bbb3 100644
--- a/modules/role/manifests/ci/slave/labs/common.pp
+++ b/modules/role/manifests/ci/slave/labs/common.pp
@@ -18,6 +18,61 @@
         require => Class['role::labs::lvm::mnt'],
     }
 
+    # New file layout based on /srv
+
+    # base directory
+    file { '/srv/jenkins':
+        ensure  => directory,
+        owner   => 'jenkins-deploy',
+        group   => 'wikidev',
+        mode    => '0775',
+        require => Mount['/srv'],
+    }
+
+    file { '/srv/jenkins/cache':
+        ensure  => directory,
+        owner   => 'jenkins-deploy',
+        group   => 'wikidev',
+        mode    => '0775',
+        require => File['/srv/jenkins'],
+    }
+
+    file { '/srv/jenkins/workspace':
+        ensure  => directory,
+        owner   => 'jenkins-deploy',
+        group   => 'wikidev',
+        mode    => '0775',
+        require => File['/srv/jenkins'],
+    }
+
+    file { '/srv/home':
+        ensure  => directory,
+        owner   => 'root',
+        group   => 'root',
+        mode    => '0755',
+        require => Mount['/srv'],
+    }
+    file { '/srv/home/jenkins-deploy':
+        ensure  => directory,
+        owner   => 'jenkins-deploy',
+        group   => 'wikidev',
+        mode    => '0775',
+        require => File['/srv/home'],
+    }
+
+    git::userconfig { '.gitconfig for jenkins-deploy user in srv':
+        homedir  => '/srv/home/jenkins-deploy',
+        settings => {
+            'user' => {
+                'name'  => 'Wikimedia Jenkins Deploy',
+                'email' => "jenkins-deploy@${::fqdn}",
+            },
+        },
+        require  => File['/srv/home/jenkins-deploy'],
+    }
+
+    ##### Legacy based on /mnt #############################
+
     # Home dir for Jenkins agent
     #
     # /var/lib and /home are too small to hold Jenkins workspaces

-- 
To view, visit https://gerrit.wikimedia.org/r/312313
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I674b49581b5ee388cc2b69329041f9d08e4c72e9
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Hashar <has...@free.fr>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to