Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-69370

New inbound agent URLs are not accessible by agents (regression in 2.364)

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • core
    • 2.365

      In Jenkins 2.364, when creating a container to perform a build, the JNLP launcher is failing with a 403 forbidden.

      I'm able to recreate the problem with both the Docker and YetAnotherDocker plugins. I'm also able to recreate the problem on the command line.

      Rolling back to Jenkins version 2.363 corrects the issue.

      YetAnotherDocker Output:
      + RUN_CMD='su - jenkins -c '"'"'java -Xmn1G -Xms4G -jar slave.jar -noReconnect -jnlpUrl https://pipeline.#####.com/test//manage/computer/corp%2Djenkins%2Dyad%2Df4ceb4c4b385//slave-agent.jnlp -secret ########################################################'"'"
      + eval 'su - jenkins -c '"'"'java -Xmn1G -Xms4G -jar slave.jar -noReconnect -jnlpUrl https://pipeline.#####.com/test//manage/computer/corp%2Djenkins%2Dyad%2Df4ceb4c4b385//slave-agent.jnlp -secret ########################################################'"'"
      + su - jenkins -c 'java -Xmn1G -Xms4G -jar slave.jar -noReconnect -jnlpUrl https://pipeline.#####.com/test//manage/computer/corp%2Djenkins%2Dyad%2Df4ceb4c4b385//slave-agent.jnlp -secret ########################################################'
      Exception in thread "main" java.io.IOException: Failed to obtain https://pipeline.#####.com/test//manage/computer/corp%2Djenkins%2Dyad%2Df4ceb4c4b385//slave-agent.jnlp?encrypt=true
      at hudson.remoting.Launcher.parseJnlpArguments(Launcher.java:567)
      at hudson.remoting.Launcher.run(Launcher.java:346)
      at hudson.remoting.Launcher.main(Launcher.java:297)
      Caused by: java.io.IOException: Failed to load https://pipeline.#####.com/test//manage/computer/corp%2Djenkins%2Dyad%2Df4ceb4c4b385//slave-agent.jnlp?encrypt=true: 403 Forbidden
      at hudson.remoting.Launcher.parseJnlpArguments(Launcher.java:514)
      ... 2 more

      Command Line:
      bash-5.1# curl -sO https://pipeline.#####.com/test/jnlpJars/agent.jar
      bash-5.1# java -jar agent.jar -jnlpUrl https://pipeline.#####.com/test/manage/computer/jenkins%2Dbc%2Ddid%2D000k7zi0cecag/jenkins-agent.jnlp -secret ########################################################
      Failed to obtain https://pipeline.#####.com/test/manage/computer/jenkins%2Dbc%2Ddid%2D000k7zi0cecag/jenkins-agent.jnlp?encrypt=true
      java.io.IOException: Failed to load https://pipeline.#####.com/test/manage/computer/jenkins%2Dbc%2Ddid%2D000k7zi0cecag/jenkins-agent.jnlp?encrypt=true: 403 Forbidden
      at hudson.remoting.Launcher.parseJnlpArguments(Launcher.java:514)
      at hudson.remoting.Launcher.run(Launcher.java:346)
      at hudson.remoting.Launcher.main(Launcher.java:297)
      Waiting 10 seconds before retry
      Failed to obtain https://pipeline.#####.com/test/manage/computer/jenkins%2Dbc%2Ddid%2D000k7zi0cecag/jenkins-agent.jnlp?encrypt=true
      java.io.IOException: Failed to load https://pipeline.#####.com/test/manage/computer/jenkins%2Dbc%2Ddid%2D000k7zi0cecag/jenkins-agent.jnlp?encrypt=true: 403 Forbidden
      at hudson.remoting.Launcher.parseJnlpArguments(Launcher.java:514)
      at hudson.remoting.Launcher.run(Launcher.java:346)
      at hudson.remoting.Launcher.main(Launcher.java:297)
      Waiting 10 seconds before retry

          [JENKINS-69370] New inbound agent URLs are not accessible by agents (regression in 2.364)

          William Gillaspy created issue -
          William Gillaspy made changes -
          Description Original: In Jenkins 2.364, when creating a container to perform a build, the JNLP launcher is failing with a 403 forbidden.

          I'm able to recreate the problem with both the Docker and YetAnotherDocker plugins. I'm also able to recreate the problem on the command line.

          *Rolling back to Jenkins version 2.363 corrects the issue.*

          *YetAnotherDocker Output:*
          + RUN_CMD='su - jenkins -c '"'"'java -Xmn1G -Xms4G -jar slave.jar -noReconnect -jnlpUrl https://pipeline.#####.com/test//manage/computer/corp%2Djenkins%2Dyad%2Df4ceb4c4b385//slave-agent.jnlp -secret ########################################################'"'"
          + eval 'su - jenkins -c '"'"'java -Xmn1G -Xms4G -jar slave.jar -noReconnect -jnlpUrl https://pipeline.#####.com/test//manage/computer/corp%2Djenkins%2Dyad%2Df4ceb4c4b385//slave-agent.jnlp -secret ########################################################'"'"
          + su - jenkins -c 'java -Xmn1G -Xms4G -jar slave.jar -noReconnect -jnlpUrl https://pipeline.#####.com/test//manage/computer/corp%2Djenkins%2Dyad%2Df4ceb4c4b385//slave-agent.jnlp -secret ########################################################'
          Exception in thread "main" java.io.IOException: Failed to obtain https://pipeline.#####.com/test//manage/computer/corp%2Djenkins%2Dyad%2Df4ceb4c4b385//slave-agent.jnlp?encrypt=true
                  at hudson.remoting.Launcher.parseJnlpArguments(Launcher.java:567)
                  at hudson.remoting.Launcher.run(Launcher.java:346)
                  at hudson.remoting.Launcher.main(Launcher.java:297)
          Caused by: java.io.IOException: Failed to load https://pipeline.#####.com/test//manage/computer/corp%2Djenkins%2Dyad%2Df4ceb4c4b385//slave-agent.jnlp?encrypt=true: 403 Forbidden
                  at hudson.remoting.Launcher.parseJnlpArguments(Launcher.java:514)
                  ... 2 more
                  
                  
          *Command Line: *
          bash-5.1# curl -sO https://pipeline.#####.com/test/jnlpJars/agent.jar
          bash-5.1# java -jar agent.jar -jnlpUrl https://pipeline.#####.com/test/manage/computer/jenkins%2Dbc%2Ddid%2D000k7zi0cecag/jenkins-agent.jnlp -secret ########################################################
          Failed to obtain https://pipeline.#####.com/test/manage/computer/jenkins%2Dbc%2Ddid%2D000k7zi0cecag/jenkins-agent.jnlp?encrypt=true
          java.io.IOException: Failed to load https://pipeline.#####.com/test/manage/computer/jenkins%2Dbc%2Ddid%2D000k7zi0cecag/jenkins-agent.jnlp?encrypt=true: 403 Forbidden
                  at hudson.remoting.Launcher.parseJnlpArguments(Launcher.java:514)
                  at hudson.remoting.Launcher.run(Launcher.java:346)
                  at hudson.remoting.Launcher.main(Launcher.java:297)
          Waiting 10 seconds before retry
          Failed to obtain https://pipeline.#####.com/test/manage/computer/jenkins%2Dbc%2Ddid%2D000k7zi0cecag/jenkins-agent.jnlp?encrypt=true
          java.io.IOException: Failed to load https://pipeline.#####.com/test/manage/computer/jenkins%2Dbc%2Ddid%2D000k7zi0cecag/jenkins-agent.jnlp?encrypt=true: 403 Forbidden
                  at hudson.remoting.Launcher.parseJnlpArguments(Launcher.java:514)
                  at hudson.remoting.Launcher.run(Launcher.java:346)
                  at hudson.remoting.Launcher.main(Launcher.java:297)
          Waiting 10 seconds before retry

          New: In Jenkins 2.364, when creating a container to perform a build, the JNLP launcher is failing with a 403 forbidden.

          I'm able to recreate the problem with both the Docker and YetAnotherDocker plugins. I'm also able to recreate the problem on the command line.

          *Rolling back to Jenkins version 2.363 corrects the issue.*

          *YetAnotherDocker Output:*
          + RUN_CMD='su - jenkins -c '"'"'java -Xmn1G -Xms4G -jar slave.jar -noReconnect -jnlpUrl https://pipeline.#####.com/test//manage/computer/corp%2Djenkins%2Dyad%2Df4ceb4c4b385//slave-agent.jnlp -secret ########################################################'"'"
          + eval 'su - jenkins -c '"'"'java -Xmn1G -Xms4G -jar slave.jar -noReconnect -jnlpUrl https://pipeline.#####.com/test//manage/computer/corp%2Djenkins%2Dyad%2Df4ceb4c4b385//slave-agent.jnlp -secret ########################################################'"'"
          + su - jenkins -c 'java -Xmn1G -Xms4G -jar slave.jar -noReconnect -jnlpUrl https://pipeline.#####.com/test//manage/computer/corp%2Djenkins%2Dyad%2Df4ceb4c4b385//slave-agent.jnlp -secret ########################################################'
          Exception in thread "main" java.io.IOException: Failed to obtain https://pipeline.#####.com/test//manage/computer/corp%2Djenkins%2Dyad%2Df4ceb4c4b385//slave-agent.jnlp?encrypt=true
                  at hudson.remoting.Launcher.parseJnlpArguments(Launcher.java:567)
                  at hudson.remoting.Launcher.run(Launcher.java:346)
                  at hudson.remoting.Launcher.main(Launcher.java:297)
          Caused by: java.io.IOException: Failed to load https://pipeline.#####.com/test//manage/computer/corp%2Djenkins%2Dyad%2Df4ceb4c4b385//slave-agent.jnlp?encrypt=true: 403 Forbidden
                  at hudson.remoting.Launcher.parseJnlpArguments(Launcher.java:514)
                  ... 2 more
                  
                  
          *Command Line:*
          bash-5.1# curl -sO https://pipeline.#####.com/test/jnlpJars/agent.jar
          bash-5.1# java -jar agent.jar -jnlpUrl https://pipeline.#####.com/test/manage/computer/jenkins%2Dbc%2Ddid%2D000k7zi0cecag/jenkins-agent.jnlp -secret ########################################################
          Failed to obtain https://pipeline.#####.com/test/manage/computer/jenkins%2Dbc%2Ddid%2D000k7zi0cecag/jenkins-agent.jnlp?encrypt=true
          java.io.IOException: Failed to load https://pipeline.#####.com/test/manage/computer/jenkins%2Dbc%2Ddid%2D000k7zi0cecag/jenkins-agent.jnlp?encrypt=true: 403 Forbidden
                  at hudson.remoting.Launcher.parseJnlpArguments(Launcher.java:514)
                  at hudson.remoting.Launcher.run(Launcher.java:346)
                  at hudson.remoting.Launcher.main(Launcher.java:297)
          Waiting 10 seconds before retry
          Failed to obtain https://pipeline.#####.com/test/manage/computer/jenkins%2Dbc%2Ddid%2D000k7zi0cecag/jenkins-agent.jnlp?encrypt=true
          java.io.IOException: Failed to load https://pipeline.#####.com/test/manage/computer/jenkins%2Dbc%2Ddid%2D000k7zi0cecag/jenkins-agent.jnlp?encrypt=true: 403 Forbidden
                  at hudson.remoting.Launcher.parseJnlpArguments(Launcher.java:514)
                  at hudson.remoting.Launcher.run(Launcher.java:346)
                  at hudson.remoting.Launcher.main(Launcher.java:297)
          Waiting 10 seconds before retry

          William Gillaspy made changes -
          Attachment New: image-2022-08-18-07-18-08-267.png [ 58783 ]
          Carlos Sanchez made changes -
          Assignee Original: Carlos Sanchez [ csanchez ]
          William Gillaspy made changes -
          Summary Original: Plugins Docker and YetAnotherDocker are receiving 403 forbidding when using JNLP New: Agents are receiving 403 forbidding when using JNLP
          Basil Crow made changes -
          Component/s New: core [ 15593 ]
          Component/s Original: docker [ 20834 ]
          Basil Crow made changes -
          Labels New: regression
          William Gillaspy made changes -
          Summary Original: Agents are receiving 403 forbidding when using JNLP New: Agents are receiving 403 forbiden when using JNLP
          William Gillaspy made changes -
          Summary Original: Agents are receiving 403 forbiden when using JNLP New: Agents are receiving 403 forbidden when using JNLP
          Basil Crow made changes -
          Summary Original: Agents are receiving 403 forbidden when using JNLP New: Agents are receiving 403 forbidden when using JNLP (regression in 2.364)
          Tim Jacomb made changes -
          Assignee New: Tim Jacomb [ timja ]

            timja Tim Jacomb
            wgillaspy William Gillaspy
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: