简体   繁体   中英

Jenkins calls batch file which needs windows environment variables. Bat file is uneditable

Basically Jenkins is calling a bat file which is proprietary and does some compilation.

Calling the file directly from command prompt works fine. However when Jenkins calls the bat file it cannot find environment variables it needs and an error is thrown that the value is unknown.

I know if I could edit the bat file I could circumvent the issue, but the file is proprietary so that is not an option. Any thoughts?

Disclaimer: Been a while since I used it (and Jenkins).

Back in the day we did this with the EnvInject plugin. Worked quite well as far as I remember it.

在此处输入图像描述

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM