Hi,
I nbeed in a jenkins pipeline to have an access to a http_proxy.
In my environment variables in my Jenkinsfile I've etted my http proxy and an env var named TOTO, then in one of my steps I checked if env var exists:
environment {
...
http_proxy = 'http://xxx:xxx'
...
TOTO='titi'
}
...
stages {
stage('xxx') {
when { anyOf { branch "${env.STABLE_BRANCH}"; branch "${http://env.DEV _BRANCH}" } } steps {
sh 'env'
sh 'env | grep TOTO'
sh 'env | grep http_proxy'
}
}
}
Résultats :
[...S3MX7KBEQ] Running shell script
+ env
+ grep TOTO
TOTO=titi
[Pipeline] sh
[...S3MX7KBEQ] Running shell script
+ env
+ grep http_proxy
[Pipeline] }
[Pipeline] // stage
[Pipeline] }
TOTO var eists but not http proxy ?!
I need this http proxy in my pipeline. is it something i missed?
Thanks