Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
I
Imldeployment
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
IML Open Source
Imldeployment
Commits
d2a687e9
Commit
d2a687e9
authored
7 years ago
by
hahn
Browse files
Options
Downloads
Patches
Plain Diff
ci server - config - detect prod system by directory
parent
407ddf56
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
hooks/templates/inc_projects_config.php.erb
+20
-14
20 additions, 14 deletions
hooks/templates/inc_projects_config.php.erb
with
20 additions
and
14 deletions
hooks/templates/inc_projects_config.php.erb
+
20
−
14
View file @
d2a687e9
...
@@ -4,7 +4,7 @@
...
@@ -4,7 +4,7 @@
//
fetch
status
infos
von
den
einzelnen
Phasen
//
fetch
status
infos
von
den
einzelnen
Phasen
//
----------------------------------------------------------------------
//
----------------------------------------------------------------------
$
aConfig =
array(
$
aConfig =
array(
//
Basispfad:
//
Basispfad:
'
workDir
'
=
>
'/var/imldeployment',
'
workDir
'
=
>
'/var/imldeployment',
'tmpDir' => '/var/tmp/imldeployment',
'tmpDir' => '/var/tmp/imldeployment',
...
@@ -101,6 +101,10 @@
...
@@ -101,6 +101,10 @@
// override for local development
// override for local development
// ----------------------------------------------------------------------
// ----------------------------------------------------------------------
// unsafe ...
// make a check that fits your environemnt
// php_uname("n") can send a short hostname (without domain)
$bProd=!!strpos(__DIR__, '/ci.iml.unibe.ch/');
switch (php_uname("n")) {
switch (php_uname("n")) {
case "USER":
case "USER":
...
@@ -112,19 +116,21 @@ switch (php_uname("n")) {
...
@@ -112,19 +116,21 @@ switch (php_uname("n")) {
case "ci.iml.unibe.ch":
case "ci.iml.unibe.ch":
case "ci":
case "ci":
// synch der Pakete nur auf dem Livesystem
if ($bProd){
$aConfig['mirrorPackages'] = array(
// synch der Pakete nur auf dem Livesystem
'puppet' => array(
$aConfig['mirrorPackages'] = array(
'type' => 'rsync',
'puppet' => array(
'runas' => 'www-data', // nur fuer commandline
'type' => 'rsync',
'target' => 'ladmin@calcium.iml.unibe.ch:/share/imldeployment',
'runas' => 'www-data', // nur fuer commandline
),
'target' => 'ladmin@calcium.iml.unibe.ch:/share/imldeployment',
'puppet.one' => array(
),
'type' => 'rsync',
'puppet.one' => array(
'runas' => 'www-data', // nur fuer commandline
'type' => 'rsync',
'target' => 'copy-deployment@puppet.one.iml.unibe.ch:/var/shared/imldeployment',
'runas' => 'www-data', // nur fuer commandline
),
'target' => 'copy-deployment@puppet.one.iml.unibe.ch:/var/shared/imldeployment',
);
),
);
}
break;
break;
default:
default:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment