S3 Copy Artifacts With Jenkings S3 Plugin











up vote
0
down vote

favorite












I am having some issues with Jenkings uploading to s3... basically we have two AWS environments, Live and Dev..



Jenkins is running on our Live environment, Has AWS access Keys, and Jenkins role from Live account..



Jenkings Role on Live has the policy as below:



{
"Version": "2012-10-17",
"Id": "Policy1541606229878898989",
"Statement": [
{
"Action": [
"s3:ListAllMyBuckets"
],
"Effect": "Allow",
"Resource": "arn:aws:s3:::*"
},
{
"Action": "s3:*",
"Effect": "Allow",
"Resource": [
"arn:aws:s3:::beta.mydomain.co.uk",
"arn:aws:s3:::beta.mydomain.co.uk/*"
]
}
]


}



beta.mydomain.co.uk - is a bucket created on Dev environment..



and the bucket Policy is a s below:



{
"Version": "2012-10-17",
"Id": "Policy1541615390300",
"Statement": [
{
"Sid": "Stmt1541606105471",
"Effect": "Allow",
"Principal": "*",
"Action": "s3:GetObject",
"Resource": "arn:aws:s3:::beta.mydomain.co.uk/*"
},
{
"Sid": "Stmt1541606206206",
"Effect": "Allow",
"Principal": {
"AWS": "arn:aws:iam::123456789987:role/Jenkins"
},
"Action": "s3:*",
"Resource": "arn:aws:s3:::beta.mydomain.co.uk/*"
}
]


}



First part of this Policy is that, any contents which get uploaded to this bucket to be public with "Principal": "*", and actions: "Action": "s3:GetObject",



Second part of this bucket policy is that to allow jenkins role setup on our productions to have full access to dump the files



My problem is that Jenkings Dumps the files all fine, but For some reason those files are not PUBLIC.... when i try to make them public i get Access denined?



any ideas please? before my hair go more grey!



thanks










share|improve this question




























    up vote
    0
    down vote

    favorite












    I am having some issues with Jenkings uploading to s3... basically we have two AWS environments, Live and Dev..



    Jenkins is running on our Live environment, Has AWS access Keys, and Jenkins role from Live account..



    Jenkings Role on Live has the policy as below:



    {
    "Version": "2012-10-17",
    "Id": "Policy1541606229878898989",
    "Statement": [
    {
    "Action": [
    "s3:ListAllMyBuckets"
    ],
    "Effect": "Allow",
    "Resource": "arn:aws:s3:::*"
    },
    {
    "Action": "s3:*",
    "Effect": "Allow",
    "Resource": [
    "arn:aws:s3:::beta.mydomain.co.uk",
    "arn:aws:s3:::beta.mydomain.co.uk/*"
    ]
    }
    ]


    }



    beta.mydomain.co.uk - is a bucket created on Dev environment..



    and the bucket Policy is a s below:



    {
    "Version": "2012-10-17",
    "Id": "Policy1541615390300",
    "Statement": [
    {
    "Sid": "Stmt1541606105471",
    "Effect": "Allow",
    "Principal": "*",
    "Action": "s3:GetObject",
    "Resource": "arn:aws:s3:::beta.mydomain.co.uk/*"
    },
    {
    "Sid": "Stmt1541606206206",
    "Effect": "Allow",
    "Principal": {
    "AWS": "arn:aws:iam::123456789987:role/Jenkins"
    },
    "Action": "s3:*",
    "Resource": "arn:aws:s3:::beta.mydomain.co.uk/*"
    }
    ]


    }



    First part of this Policy is that, any contents which get uploaded to this bucket to be public with "Principal": "*", and actions: "Action": "s3:GetObject",



    Second part of this bucket policy is that to allow jenkins role setup on our productions to have full access to dump the files



    My problem is that Jenkings Dumps the files all fine, but For some reason those files are not PUBLIC.... when i try to make them public i get Access denined?



    any ideas please? before my hair go more grey!



    thanks










    share|improve this question


























      up vote
      0
      down vote

      favorite









      up vote
      0
      down vote

      favorite











      I am having some issues with Jenkings uploading to s3... basically we have two AWS environments, Live and Dev..



      Jenkins is running on our Live environment, Has AWS access Keys, and Jenkins role from Live account..



      Jenkings Role on Live has the policy as below:



      {
      "Version": "2012-10-17",
      "Id": "Policy1541606229878898989",
      "Statement": [
      {
      "Action": [
      "s3:ListAllMyBuckets"
      ],
      "Effect": "Allow",
      "Resource": "arn:aws:s3:::*"
      },
      {
      "Action": "s3:*",
      "Effect": "Allow",
      "Resource": [
      "arn:aws:s3:::beta.mydomain.co.uk",
      "arn:aws:s3:::beta.mydomain.co.uk/*"
      ]
      }
      ]


      }



      beta.mydomain.co.uk - is a bucket created on Dev environment..



      and the bucket Policy is a s below:



      {
      "Version": "2012-10-17",
      "Id": "Policy1541615390300",
      "Statement": [
      {
      "Sid": "Stmt1541606105471",
      "Effect": "Allow",
      "Principal": "*",
      "Action": "s3:GetObject",
      "Resource": "arn:aws:s3:::beta.mydomain.co.uk/*"
      },
      {
      "Sid": "Stmt1541606206206",
      "Effect": "Allow",
      "Principal": {
      "AWS": "arn:aws:iam::123456789987:role/Jenkins"
      },
      "Action": "s3:*",
      "Resource": "arn:aws:s3:::beta.mydomain.co.uk/*"
      }
      ]


      }



      First part of this Policy is that, any contents which get uploaded to this bucket to be public with "Principal": "*", and actions: "Action": "s3:GetObject",



      Second part of this bucket policy is that to allow jenkins role setup on our productions to have full access to dump the files



      My problem is that Jenkings Dumps the files all fine, but For some reason those files are not PUBLIC.... when i try to make them public i get Access denined?



      any ideas please? before my hair go more grey!



      thanks










      share|improve this question















      I am having some issues with Jenkings uploading to s3... basically we have two AWS environments, Live and Dev..



      Jenkins is running on our Live environment, Has AWS access Keys, and Jenkins role from Live account..



      Jenkings Role on Live has the policy as below:



      {
      "Version": "2012-10-17",
      "Id": "Policy1541606229878898989",
      "Statement": [
      {
      "Action": [
      "s3:ListAllMyBuckets"
      ],
      "Effect": "Allow",
      "Resource": "arn:aws:s3:::*"
      },
      {
      "Action": "s3:*",
      "Effect": "Allow",
      "Resource": [
      "arn:aws:s3:::beta.mydomain.co.uk",
      "arn:aws:s3:::beta.mydomain.co.uk/*"
      ]
      }
      ]


      }



      beta.mydomain.co.uk - is a bucket created on Dev environment..



      and the bucket Policy is a s below:



      {
      "Version": "2012-10-17",
      "Id": "Policy1541615390300",
      "Statement": [
      {
      "Sid": "Stmt1541606105471",
      "Effect": "Allow",
      "Principal": "*",
      "Action": "s3:GetObject",
      "Resource": "arn:aws:s3:::beta.mydomain.co.uk/*"
      },
      {
      "Sid": "Stmt1541606206206",
      "Effect": "Allow",
      "Principal": {
      "AWS": "arn:aws:iam::123456789987:role/Jenkins"
      },
      "Action": "s3:*",
      "Resource": "arn:aws:s3:::beta.mydomain.co.uk/*"
      }
      ]


      }



      First part of this Policy is that, any contents which get uploaded to this bucket to be public with "Principal": "*", and actions: "Action": "s3:GetObject",



      Second part of this bucket policy is that to allow jenkins role setup on our productions to have full access to dump the files



      My problem is that Jenkings Dumps the files all fine, but For some reason those files are not PUBLIC.... when i try to make them public i get Access denined?



      any ideas please? before my hair go more grey!



      thanks







      amazon-web-services jenkins amazon-s3 jenkins-plugins amazon-iam






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Nov 8 at 10:34

























      asked Nov 7 at 18:53









      Jenna Shaik

      64




      64





























          active

          oldest

          votes











          Your Answer






          StackExchange.ifUsing("editor", function () {
          StackExchange.using("externalEditor", function () {
          StackExchange.using("snippets", function () {
          StackExchange.snippets.init();
          });
          });
          }, "code-snippets");

          StackExchange.ready(function() {
          var channelOptions = {
          tags: "".split(" "),
          id: "1"
          };
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function() {
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled) {
          StackExchange.using("snippets", function() {
          createEditor();
          });
          }
          else {
          createEditor();
          }
          });

          function createEditor() {
          StackExchange.prepareEditor({
          heartbeatType: 'answer',
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader: {
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          },
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          });


          }
          });














           

          draft saved


          draft discarded


















          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53195957%2fs3-copy-artifacts-with-jenkings-s3-plugin%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown






























          active

          oldest

          votes













          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes
















           

          draft saved


          draft discarded



















































           


          draft saved


          draft discarded














          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53195957%2fs3-copy-artifacts-with-jenkings-s3-plugin%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          Schultheiß

          Verwaltungsgliederung Dänemarks

          Liste der Kulturdenkmale in Wilsdruff