Skip to content
Snippets Groups Projects
Select Git revision
  • 248f5add5c8129449aededb634f78cb11dd1d0d9
  • master default protected
  • 7771-harden-postgres-backup
  • pgsql-dump-with-snapshots
  • update-colors
  • update-docs-css
  • usb-repair-stick
  • desktop-notification
  • 7000-corrections
  • db-detector
10 results

jobhelper.sh

Blame
  • config_defaults.php 5.91 KiB
    <?php
    /*
     * DEFAULT CONFIG SETTINGS
     * 
     * Do not change this file. For custom settings use the config_custom.php
     * and override wanted keys.
     * 
     */
    return [
    
        // ----------------------------------------------------------------------    
    
        'workDir' => '/var/imldeployment',
        'tmpDir' => '/var/tmp/imldeployment',
    
        // ----------------------------------------------------------------------    
    
        'phases' => [
            "preview" => [
                'css' => [
                    'bgdark' => 'background:#393E50;  color:#f8f8f8;',
                    'bglight' => 'background:#eee; color:#333; background:rgba(210,210,210,0.3); ',
                    'bgbutton' => 'background:#393E50; color:#fcfcfc; border: 1px solid rgba(0,0,0,0.15);',
                ],
            ],
            "stage" => [
                'css' => [
                    'bgdark' => 'background:#3F88C5; color:#f8f8f8;',
                    'bglight' => 'background:#f0f4f8; color:#333; background:rgba(200,210,220,0.3); ',
                    'bgbutton' => 'background:#3F88C5; color:#fcfcfc; border: 1px solid rgba(0,0,0,0.15);',
                ],
            ],
            "live" => [
                'css' => [
                    'bgdark' => 'background:#44BBA4; color:#f8f8f8;',
                    'bglight' => 'background:#f4f8f0; color:#333; background:rgba(210,220,200,0.3); ',
                    'bgbutton' => 'background:#44BBA4; color:#fcfcfc; border: 1px solid rgba(0,0,0,0.15);',
                ],
                // prevent immediate installation after build or accept
                "deploytimes" => ['/(Mon|Tue|Wed|Thu)\ 14\:/'],
            ],
        ],
    
        'auth' => [
            // force using a given user ... for development only
            'forceuser' => 'admin',
    
            // use a real login
            'ldap' => [
                'server'       => 'ldaps://ldap.example.com',
                'port'         => 636,
                'DnLdapUser' => 'cn=lookupuser,dc=department,dc=example.com',
                'PwLdapUser' => 'lookupuser_password_here',
                'DnUserNode'   => 'ou=People,dc=department,dc=example.com',
                'DnAppNode'    => 'cn=CI Web-GUI Users,ou=Application Access,dc=department,dc=example.com',
                'debugLevel'   => 0,
            ]
        ],
    
        'lang' => 'en-en', // for available languages see ./config/lang/*.json
    
        'showdebug' => [
            'ip'=> ['127.0.0.1'],
        ],
        'projectgroups' => [
            'teamA'=>'Team A: Services',
            'teamB'=>'Team B: Website',
        ],
        
        // ----------------------------------------------------------------------
        // build settings
        // ----------------------------------------------------------------------
        'versionsToKeep' => 10, // for cleanup: keep n unused versions
        'builtsToKeep' => 3,
        'build' => [
            'env' => 'export RVMSCRIPT="/usr/local/rvm/scripts/rvm";',
            'hooks' => [
                'build-postclone' => 'hooks/onbuild-postclone',
                'build-precompress' => 'hooks/onbuild',
            ],
        ],
    
        // ----------------------------------------------------------------------
        // sync of archives
        // ----------------------------------------------------------------------
        'mirrorPackages' => [
            /*
    
            // (1)
            // sync to a puppet master puppet to extract archive and generate templates
            'puppet' => array(
                'type' => 'rsync',
                'runas' => '', // www-data, // nur fuer commandline
                'target' => 'copy-deployment@puppetmaster.example.com:/share/ciserver',
            ),
    
            // (2)
            // sync to a software package server like https://os-docs.iml.unibe.ch/ci-pkg/
            'package-server' => array(
                'type' => 'rsync',
                'runas' => '', // apache httpd user is default, e.g. www-data
                'target' => 'copy-deployment@software.example.com:/var/www/data-ciserver',
            ),
            */
        ],
    
        // ----------------------------------------------------------------------    
        // plugins
        // existing subkeys = enabled plugins
        // ----------------------------------------------------------------------    
        'plugins'=>[
            'rollout'=>[
                'default'=>[],
                /*
                'ssh'=>[
                    'user'=>'deployment',
                    'privatekey'=>'',
                    'addkeycommand'=>'/usr/bin/ssh-keygen -R %s; /usr/bin/ssh-keyscan -t rsa %s >> /home/www-data/.ssh/known_hosts',
                    'testcommand'=>'sudo puppet --version',
                    'command'=>'/usr/local/bin/puppetrun.sh',
                ],
                'awx'=>[
                    'url'=>'https://awx.example.com/api/v2', // no ending "/"
                    'user'=>'ciserver',
                    'password'=>'ciserver',
                    'jobtemplate'=>'36',
                    'tags'=>'rollout',
                ],
                */
            ],
        ],
        
        // ----------------------------------------------------------------------    
        // notifications to messengers ...
        // ----------------------------------------------------------------------    
        'messenger'=>[
            'slack'=>[
                'presets'=>[],
            ],
            'email'=>[
                'from'=>'noreply@ciserver.example.com',
            ]
        ],
    
        // ----------------------------------------------------------------------    
        // TODO: functionality to be removed?!
        // ----------------------------------------------------------------------    
    
        'foreman__' => [
            'api'=>'https://foreman.example.com/', // with ending "/"
            'user'=>'ci-server',
            'password'=>'ciserver_password_here',
            'ignore-ssl-error'=>true,
            // 'varname-replace'=>'ci-replacement',
        ],
    
        // where to store project data
        'projects' => [
            'json' => [
                'active'       => true,
            ],
            'ldap' => [
                'active'       => false,
            ],
        ],
        // ----------------------------------------------------------------------    
    
    ];