-
Notifications
You must be signed in to change notification settings - Fork 906
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the bug
Hello,
I'm trying to use .controller.jenkinsOpts
value to set jenkins options such as:
jenkinsOpts: >-
-Djenkins.install.runSetupWizard=false
-Dorg.jenkinsci.plugins.pipeline.modeldefinition.parser.RuntimeASTTransformer.SCRIPT_SPLITTING_TRANSFORMATION=true
-Dorg.jenkinsci.plugins.pipeline.modeldefinition.parser.RuntimeASTTransformer.SCRIPT_SPLITTING_ALLOW_LOCAL_VARIABLES=true
-Dorg.apache.commons.jelly.tags.fmt.timeZone=Europe/Paris
-Djenkins.model.Jenkins.crumbIssuerProxyCompatibility=true
-Dhudson.security.csrf.GlobalCrumbIssuerConfiguration.DISABLE_CSRF_PROTECTION=false
-Dcom.cloudbees.workflow.rest.external.JobExt.maxRunsPerJob=32
-Dorg.jenkinsci.plugins.workflow.cps.LoggingInvoker.fieldSetWarning=false
But when Jenkins start, I have this error:
Running from: /usr/share/jenkins/jenkins.war
Exception in thread "main" java.lang.IllegalArgumentException: Multiple command line argument specified: -Dorg.jenkinsci.plugins.pipeline.modeldefinition.parser.RuntimeASTTransformer.SCRIPT_SPLITTING_TRANSFORMATION=true
at Jenkins Main ClassLoader//winstone.cmdline.CmdLineParser.parse(CmdLineParser.java:69)
at Jenkins Main ClassLoader//winstone.Launcher.getArgsFromCommandLine(Launcher.java:498)
at Jenkins Main ClassLoader//winstone.Launcher.main(Launcher.java:462)
at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(Unknown Source)
at java.base/java.lang.reflect.Method.invoke(Unknown Source)
at executable.Main.main(Main.java:335)
I tried with to set the value in one line
controller:
jenkinsOpts: "-Djenkins.install.runSetupWizard=false -Dorg.jenkinsci.plugins.pipeline.modeldefinition.parser.RuntimeASTTransformer.SCRIPT_SPLITTING_TRANSFORMATION=true -Dorg.jenkinsci.plugins.pipeline.modeldefinition.parser.RuntimeASTTransformer.SCRIPT_SPLITTING_ALLOW_LOCAL_VARIABLES=true -Dorg.apache.commons.jelly.tags.fmt.timeZone=Europe/Paris -Djenkins.model.Jenkins.crumbIssuerProxyCompatibility=true -Dhudson.security.csrf.GlobalCrumbIssuerConfiguration.DISABLE_CSRF_PROTECTION=false -Dcom.cloudbees.workflow.rest.external.JobExt.maxRunsPerJob=32 -Dorg.jenkinsci.plugins.workflow.cps.LoggingInvoker.fieldSetWarning=false"
But the bug persist.
When I dump the statefulSet YAML, the JENKINS_OPTS
env var value is on multi lines
- name: JENKINS_OPTS
value: --webroot=/var/jenkins_cache/war -Djenkins.install.runSetupWizard=false
-Dorg.jenkinsci.plugins.pipeline.modeldefinition.parser.RuntimeASTTransformer.SCRIPT_SPLITTING_TRANSFORMATION=true
-Dorg.jenkinsci.plugins.pipeline.modeldefinition.parser.RuntimeASTTransformer.SCRIPT_SPLITTING_ALLOW_LOCAL_VARIABLES=true
-Dorg.apache.commons.jelly.tags.fmt.timeZone=Europe/Paris -Djenkins.model.Jenkins.crumbIssuerProxyCompatibility=true
-Dhudson.security.csrf.GlobalCrumbIssuerConfiguration.DISABLE_CSRF_PROTECTION=false
-Dcom.cloudbees.workflow.rest.external.JobExt.maxRunsPerJob=32 -Dorg.jenkinsci.plugins.workflow.cps.LoggingInvoker.fieldSetWarning=false
I can't get the value to be on one line.
Version of Helm and Kubernetes
- Helm: fluxcd helm-controller 1.3 (Helm v3.17.3)
- Kubernetes: EKS 1.33
Chart version
5.8.83
What happened?
Bad generated YAML?
What you expected to happen?
No response
How to reproduce it
Set `controller.jenkinsOpts` with long value containing multiples jenkins options.
Anything else we need to know?
No response
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working