diff --git a/Jenkinsfile b/Jenkinsfile index 200733d..ec39a2a 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -14,7 +14,22 @@ pipeline { triggers { cron('0 5 * * 0-7') } - + + environment { + EMEA_PROD_API_TOKEN = credentials('EUPROD_TOKEN_VAR') + EMEA_PROD_ENV_URL = 'https://xxu26128.live.dynatrace.com' + EMEA_PREPROD_API_TOKEN = credentials('EUPREPROD_TOKEN_VAR') + EMEA_PREPROD_ENV_URL = 'https://qqk70169.live.dynatrace.com' + NA_PROD_API_TOKEN = credentials('NAPROD_TOKEN_VAR') + NA_PROD_ENV_URL = 'https://wgv50241.live.dynatrace.com' + NA_PREPROD_API_TOKEN = credentials('NAPREPROD_TOKEN_VAR') + NA_PREPROD_ENV_URL = 'https://onb44935.live.dynatrace.com' + CN_PROD_API_TOKEN = credentials('CNPROD_TOKEN_VAR') + CN_PROD_ENV_URL= 'https://dynatracemgd-tsp.bmwgroup.net/e/b921f1b9-c00e-4031-b9d1-f5a0d530757b' + CN_PREPROD_API_TOKEN = credentials('CNPREPROD_TOKEN_VAR') + CN_PREPROD_ENV_URL = 'https://dynatracemgd-tsp.bmwgroup.net/e/ab88c03b-b7fc-45f0-9115-9e9ecc0ced35' + } + stages { stage('Fetch Data') { steps { @@ -81,20 +96,7 @@ pipeline { sleep(300*exportRetryCount) script { exportRetryCount = exportRetryCount + 1 - env.EMEA_PROD_API_TOKEN = credentials('EUPROD_TOKEN_VAR') - env.EMEA_PROD_ENV_URL = 'https://xxu26128.live.dynatrace.com' - env.EMEA_PREPROD_API_TOKEN = credentials('EUPREPROD_TOKEN_VAR') - env.EMEA_PREPROD_ENV_URL = 'https://qqk70169.live.dynatrace.com' - env.NA_PROD_API_TOKEN = credentials('NAPROD_TOKEN_VAR') - env.NA_PROD_ENV_URL = 'https://wgv50241.live.dynatrace.com' - env.NA_PREPROD_API_TOKEN = credentials('NAPREPROD_TOKEN_VAR') - env.NA_PREPROD_ENV_URL = 'https://onb44935.live.dynatrace.com' - env.CN_PROD_API_TOKEN = credentials('CNPROD_TOKEN_VAR') - env.CN_PROD_ENV_URL= 'https://dynatracemgd-tsp.bmwgroup.net/e/b921f1b9-c00e-4031-b9d1-f5a0d530757b' - env.CN_PREPROD_API_TOKEN = credentials('CNPREPROD_TOKEN_VAR') - env.CN_PREPROD_ENV_URL = 'https://dynatracemgd-tsp.bmwgroup.net/e/ab88c03b-b7fc-45f0-9115-9e9ecc0ced35' sh "chmod 755 terraform-provider-dynatrace_v1.30.2" - // result = bat label: 'Execute python script..', returnStatus: true, script: "export.py" sh "sudo python3 export.py" } }