Skip to content
Snippets Groups Projects
Commit 4365fab0 authored by Alex Iribarren's avatar Alex Iribarren
Browse files

Save the variables in files instead

parent 74ab3472
No related branches found
No related tags found
1 merge request!4Improve handling of variables
Pipeline #524464 failed
...@@ -6,9 +6,8 @@ variables: ...@@ -6,9 +6,8 @@ variables:
VAULT_ADDR: "https://${CLUSTER_ADDR}:8200" VAULT_ADDR: "https://${CLUSTER_ADDR}:8200"
before_script: before_script:
- if [[ $CI_COMMIT_REF_NAME == 'master' || -n ${CI_COMMIT_TAG+x} ]]; then PREFIX='PROD_'; else PREFIX='DEV_'; fi - if [[ $CI_COMMIT_REF_NAME == 'master' || -n ${CI_COMMIT_TAG+x} ]]; then PREFIX='prod'; else PREFIX='dev'; fi
- eval 'vars=${!'"$PREFIX"'@}' - source ${PREFIX}.variables.sh
- for v in $vars; do eval 'export '"${v#$PREFIX}"'=$'$v; done
stages: stages:
- prepare - prepare
...@@ -21,8 +20,8 @@ stages: ...@@ -21,8 +20,8 @@ stages:
prepare_dirs: prepare_dirs:
stage: prepare stage: prepare
script: script:
- cp -r ${REPOS}/ scheduler/ - cp -r ${REPOS} scheduler/yum.repos.d
- cp repos.yaml scheduler/ - cp ${REPOSCONF} scheduler/repos.yaml
artifacts: artifacts:
paths: paths:
- scheduler/yum.repos.d/ - scheduler/yum.repos.d/
......
[downloads.mariadb.comm-maxscale-x86_64-el5]
name=MariaDB maxscale for Centos 5
baseurl=https://downloads.mariadb.com/MaxScale/2.0.2/centos/5/x86_64/
enabled=1
gpgcheck=0
[downloads.mariadb.com-maxscale-x86_64-el6]
name=MariaDB maxscale for Centos 6
baseurl=https://downloads.mariadb.com/MaxScale/2.0.2/centos/6/x86_64/
enabled=1
gpgcheck=0
[downloads.mariadb.com-maxscale-x86_64-el7]
name=MariaDB maxscale for Centos 7
baseurl=https://downloads.mariadb.com/MaxScale/2.0.2/centos/7/x86_64/
enabled=1
gpgcheck=0
[eolopenstackel6]
name=openstack juno el6
baseurl=http://mirror.centos.org/centos/6/cloud/x86_64/openstack-juno/
enabled=1
gpgcheck=0
[xrootd-stable-5-i386]
name=xrootd stable 5 i386
baseurl=http://xrootd.cern.ch/sw/repos/stable/slc/5/i386/
enabled=1
gpgcheck=0
[xrootd-stable-5-x86_64]
name=xrootd stable 5 x86_64
baseurl=http://xrootd.cern.ch/sw/repos/stable/slc/5/x86_64/
enabled=1
gpgcheck=0
[xrootd-stable-6-i386]
name=xrootd stable 6 i386
baseurl=http://xrootd.cern.ch/sw/repos/stable/slc/6/i386/
enabled=1
gpgcheck=0
[xrootd-stable-6-x86_64]
name=xrootd stable 6 x86_64
baseurl=http://xrootd.cern.ch/sw/repos/stable/slc/6/x86_64/
enabled=1
gpgcheck=0
[xrootd-stable-7-x86_64]
name=xrootd stable 7 x86_64
baseurl=http://xrootd.cern.ch/sw/repos/stable/slc/7/x86_64/
enabled=1
gpgcheck=0
[xrootd-testing-5-i386]
name=xrootd testing 5 i386
baseurl=http://xrootd.cern.ch/sw/repos/testing/slc/5/i386/
enabled=1
gpgcheck=0
[xrootd-testing-5-x86_64]
name=xrootd testing 5 x86_64
baseurl=http://xrootd.cern.ch/sw/repos/testing/slc/5/x86_64/
enabled=1
gpgcheck=0
[xrootd-testing-6-i386]
name=xrootd testing 6 i386
baseurl=http://xrootd.cern.ch/sw/repos/testing/slc/6/i386/
enabled=1
gpgcheck=0
[xrootd-testing-6-x86_64]
name=xrootd testing 6 x86_64
baseurl=http://xrootd.cern.ch/sw/repos/testing/slc/6/x86_64/
enabled=1
gpgcheck=0
[xrootd-testing-7-x86_64]
name=xrootd testing 7 x86_64
baseurl=http://xrootd.cern.ch/sw/repos/testing/slc/7/x86_64/
enabled=1
gpgcheck=0
---
# YAML configuration file
# Add a dictionary for each .repo file where you want to overwrite the defaults.
# The following keys are valid:
# pathroot: prefix of destination directory. Default: ""
# pathcut: cut the sync URL up to this point. What remains will be
# appended to "$PATHROOT/" to build the destination directory.
# Default: "//"
#theforeman.repo:
# pathroot: foreman
# pathcut: yum.theforeman.org
#xrootd.repo:
# pathroot: xrootd
JOB_PREFIX="dev_"
MOUNT_POINT="/mnt/data2/test/repos"
REPOS="dev.repos.d"
REPOSCONF="dev.repos.yaml"
SCHEDULE="* * * * *"
JOB_PREFIX="prod_"
MOUNT_POINT="/mnt/data2/test/repos2"
REPOS="yum.repos.d"
REPOSCONF="repos.yaml"
SCHEDULE="0 */12 * * *"
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment