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

S3 plugin Configuration as Code support

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

      I haven't found a way how to configure the plugin via CasC. There's nothing in the exported YAML or anywhere else.

       

      It would be great to have the support.

        Attachments

          Issue Links

            Activity

            Hide
            jholusa Jiri Holusa added a comment -

            Alexander A I was digging through the code.

            I tried following snippet:

            
            {color:#000080}s3upload:
            {color}{color:#000080}  profiles:
            {color}     - {color:#000080}name: {color}{color:#008000}"jenkins-profile"
            {color}       {color:#000080}accessKey: {color}{color:#008000}"haha"
            {color}       {color:#000080}secretKey: {color}{color:#008000}"haha"{color}
            
            

             

            But it didn't work with stacktrace:

            
            Invalid configuration elements for type class hudson.plugins.s3.S3BucketPublisher$DescriptorImpl : profiles.
            
            

             

            So kept digging. I think it's not possible because https://github.com/jenkinsci/s3-plugin/blob/master/src/main/java/hudson/plugins/s3/S3BucketPublisher.java#L394 , the field is private and there is no constructor for it. Now I'm stuck. I'm willing to invest some time into this and make it work, but I need some guidenance. Any thoughts? Or perhaps Nicolas De Loof ?

            Show
            jholusa Jiri Holusa added a comment - Alexander A I was digging through the code. I tried following snippet: {color:#000080}s3upload: {color}{color:#000080}  profiles: {color}     - {color:#000080}name: {color}{color:#008000} "jenkins-profile" {color}       {color:#000080}accessKey: {color}{color:#008000} "haha" {color}       {color:#000080}secretKey: {color}{color:#008000} "haha" {color}   But it didn't work with stacktrace: Invalid configuration elements for type class hudson.plugins.s3.S3BucketPublisher$DescriptorImpl : profiles.   So kept digging. I think it's not possible because https://github.com/jenkinsci/s3-plugin/blob/master/src/main/java/hudson/plugins/s3/S3BucketPublisher.java#L394 , the field is private and there is no constructor for it. Now I'm stuck. I'm willing to invest some time into this and make it work, but I need some guidenance. Any thoughts? Or perhaps Nicolas De Loof ?
            Hide
            jholusa Jiri Holusa added a comment -

            I figured it out and sent a PR: https://github.com/jenkinsci/s3-plugin/pull/118

            Show
            jholusa Jiri Holusa added a comment - I figured it out and sent a PR: https://github.com/jenkinsci/s3-plugin/pull/118

              People

              • Assignee:
                jholusa Jiri Holusa
                Reporter:
                jholusa Jiri Holusa
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated: