We have copied our Jenkins instance to have an identical test Jenkins. Is there a *proper* way to distinguish between production Jenkins and test Jenkins within a Scripted Pipeline?
We need different behaviour for some parts of our builds, like publishing Yum artifacts, git tagging releases. This we need to check if the running Jenkins instance is either production or test. I know we can check the environment variable JENKINS_URL, but that is not a good solution. It would require us to have the both URLs defined in our shared pipeline scripts. def environments [:] environments["PRODUCTION"] = "https://build-ci.company.com:8443" environments["TEST"] = "https://build-ci-test.company.com:8443" -- You received this message because you are subscribed to the Google Groups "Jenkins Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/20c2cb4a-8473-47dc-aa40-e513df77d589%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.