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

Cannot use jenkins-cli with github oauth plugin

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

      I'm using the github-oauth plugin for authentication and the Github Commiter Authorization Strategy and I'm unable to use the jenkins-cli with it. Running this command:

      java -jar jenkins-cli.jar -s http://localhost:8080 who-am-i --username <username> --password <jenkins-api-token> 

      results in an error:

      "--username" is not a valid option
      java -jar jenkins-cli.jar who-am-i
      Reports your credential and permissions.
      

      I've also tried ssh key auth with the -i flag but get a similar error about -i being an invalid option.

      Is there another way to use jenkins-cli with github auth?

        Attachments

          Issue Links

            Activity

            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Sam Gleske
            Path:
            .mvn/jvm.config
            LICENSE.txt
            src/main/java/org/jenkinsci/plugins/GithubSecurityRealm.java
            src/test/java/org/jenkinsci/plugins/GithubSecurityRealmTest.java
            http://jenkins-ci.org/commit/github-oauth-plugin/3eeba9ca2e24d00a2f6677a44c41c9527df0b9b1
            Log:
            Merge pull request #77 from jenkinsci/jenkins-cli-token

            JENKINS-27045 Jenkins CLI -username/-password options

            Compare: https://github.com/jenkinsci/github-oauth-plugin/compare/120f8ec9a7a5...3eeba9ca2e24

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Sam Gleske Path: .mvn/jvm.config LICENSE.txt src/main/java/org/jenkinsci/plugins/GithubSecurityRealm.java src/test/java/org/jenkinsci/plugins/GithubSecurityRealmTest.java http://jenkins-ci.org/commit/github-oauth-plugin/3eeba9ca2e24d00a2f6677a44c41c9527df0b9b1 Log: Merge pull request #77 from jenkinsci/jenkins-cli-token JENKINS-27045 Jenkins CLI - username/ -password options Compare: https://github.com/jenkinsci/github-oauth-plugin/compare/120f8ec9a7a5...3eeba9ca2e24
            Hide
            jglick Jesse Glick added a comment -

            So should this now be Resolved/Fixed?

            Show
            jglick Jesse Glick added a comment - So should this now be Resolved/Fixed?
            Hide
            jhoblitt Joshua Hoblitt added a comment -

            What version of the core is needed to test this?

            Show
            jhoblitt Joshua Hoblitt added a comment - What version of the core is needed to test this?
            Show
            sag47 Sam Gleske added a comment - Joshua Hoblitt https://github.com/jenkinsci/github-oauth-plugin/blob/github-oauth-0.25/pom.xml#L16-L17
            Show
            sag47 Sam Gleske added a comment - Resolved by https://github.com/jenkinsci/github-oauth-plugin/pull/77

              People

              • Assignee:
                sag47 Sam Gleske
                Reporter:
                heydrick Eric Heydrick
              • Votes:
                4 Vote for this issue
                Watchers:
                9 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: