{"id":17326,"date":"2025-06-03T10:00:00","date_gmt":"2025-06-03T01:00:00","guid":{"rendered":"https:\/\/www.ecomottblog.com\/?p=17326"},"modified":"2025-05-30T22:59:26","modified_gmt":"2025-05-30T13:59:26","slug":"%e3%80%90%e9%9d%a9%e5%91%bd%e3%80%91github-actions%e3%81%a7react%e3%82%92aws%e7%92%b0%e5%a2%83%e3%81%b8%e8%87%aa%e5%8b%95%e3%83%87%e3%83%97%e3%83%ad%e3%82%a4","status":"publish","type":"post","link":"https:\/\/www.ecomottblog.com\/?p=17326","title":{"rendered":"\u3010\u9769\u547d\u3011GitHub Actions\u3067React\u3092AWS\u74b0\u5883\u3078\u81ea\u52d5\u30c7\u30d7\u30ed\u30a4"},"content":{"rendered":"\u3053\u3093\u306b\u3061\u306f\uff01\u30af\u30e9\u30a6\u30c9\u30bd\u30ea\u30e5\u30fc\u30b7\u30e7\u30f3\u958b\u767a\u90e8\u306e\u897f\u8c37\u3067\u3059\u3002GitHub Actions\u3092\u4f7f\u3063\u3066React\u3067\u5b9f\u88c5\u3057\u305f\u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u3092AWS\u74b0\u5883\u3078\u81ea\u52d5\u30c7\u30d7\u30ed\u30a4\u8a2d\u5b9a\u3057\u3001\u696d\u52d9\u52b9\u7387\u3092\u5411\u4e0a\u3055\u305b\u307e\u3057\u305f\u3002\u624b\u8efd\u306b\u5b9f\u8df5\u3067\u304d\u308b\u306e\u3067\u60c5\u5831\u3092\u30b7\u30a7\u30a2\u3057\u307e\u3059\u3002\n\n<!-- \/wp:paragraph -->\n\n<!-- wp:more -->\n\n<!--more-->\n\n<h2>\u306f\u3058\u3081\u306b<\/h2>\n\n\u73fe\u5728\u643a\u308f\u3063\u3066\u3044\u308b\u958b\u767a\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3067\u306fReact\u3067\u30d5\u30ed\u30f3\u30c8\u30a8\u30f3\u30c9\u958b\u767a\u3092\u884c\u3063\u3066\u3044\u307e\u3059\u3002 \u305d\u306e\u4e2d\u3067\u3001\u958b\u767a\u4e2d\u306eUI\u304c\u60f3\u5b9a\u901a\u308a\u306e\u3082\u306e\u306b\u306a\u3063\u3066\u3044\u308b\u304b\u3092\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u306b\u78ba\u8a8d\u3057\u3066\u3082\u3089\u3046\u305f\u3081\u306b\u3001\u304b\u306a\u308a\u76db\u3093\u306b\u30c7\u30d7\u30ed\u30a4\u3092\u884c\u3063\u3066\u3044\u307e\u3059\u3002 \u305f\u3060\u3053\u306e\u30c7\u30d7\u30ed\u30a4\u3092\u624b\u52d5\u3067\u3084\u308b\u3068\u305d\u308c\u306a\u308a\u306b\u624b\u9593\u304c\u304b\u304b\u3063\u3066\u3057\u307e\u3046\u3068\u3044\u3046\u3053\u3068\u304b\u3089\u3001GitHub Actions\u3067\u81ea\u52d5\u30c7\u30d7\u30ed\u30a4\u3092\u8a2d\u5b9a\u3059\u308b\u3053\u3068\u306b\u3057\u307e\u3057\u305f\u3002 \u8a2d\u5b9a\u3057\u3066\u307f\u305f\u7d50\u679c\u3001\u304b\u306a\u308a\u597d\u611f\u89e6\u3060\u3063\u305f\u306e\u3067\u8a18\u4e8b\u306b\u3057\u3088\u3046\u3068\u601d\u3044\u307e\u3059\u3002\n\n<h2>\u524d\u63d0<\/h2>\n\n<ul>\n    <li>React19 + Vite<\/li>\n    <li>AWS CloudFront + S3<\/li>\n<\/ul>\n\n<h2>\u8a2d\u5b9a\u3059\u308bGitHub Actions<\/h2>\n\nGitHub Actions\u3092\u4e00\u8a00\u3067\u8aac\u660e\u3059\u308b\u3068\u3001\u300cGitHub\u4e0a\u3067\u884c\u308f\u308c\u305f\u4f55\u304b\u3057\u3089\u306e\u64cd\u4f5c\u3092\u30c8\u30ea\u30ac\u30fc\u306b\u3001\u5b9a\u7fa9\u3057\u305f\u64cd\u4f5c\u3092\u81ea\u52d5\u3067\u5b9f\u884c\u3059\u308b\u305f\u3081\u306e\u6a5f\u80fd\u300d\u3067\u3059\u3002\n\u3053\u306e\u300c\u5b9a\u7fa9\u300d\u304c\u66f8\u304b\u308c\u305f\u30d5\u30a1\u30a4\u30eb\u3092\u30ef\u30fc\u30af\u30d5\u30ed\u30fc\u3068\u547c\u3073\u307e\u3059\u3002\u3053\u306e\u30ef\u30fc\u30af\u30d5\u30ed\u30fc\u3092\u30ea\u30dd\u30b8\u30c8\u30ea\u306e<code>.github\/workflows<\/code>\u306b\u4fdd\u5b58\u3059\u308b\u3053\u3068\u3067\u5b9f\u884c\u3067\u304d\u308b\u3088\u3046\u306b\u306a\u308a\u307e\u3059\u3002\n\u4eca\u56de\u79c1\u304c\u8a2d\u5b9a\u3057\u305f\u306e\u306f\u3001\u4e0b\u8a18\u306e\u6dfb\u4ed8\u753b\u50cf\u306e\u901a\u308a\u3001\u7279\u5b9a\u306e\u30d6\u30e9\u30f3\u30c1\u306b\u30de\u30fc\u30b8\u3055\u308c\u305f\u3089\u81ea\u52d5\u30d3\u30eb\u30c9&amp;\u30c7\u30d7\u30ed\u30a4\u3092\u884c\u3046\u30ef\u30fc\u30af\u30d5\u30ed\u30fc\u3067\u3059\u3002\n\n&nbsp;\n\n<img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-17329 aligncenter\" src=\"https:\/\/www.ecomottblog.com\/wp-content\/uploads\/2025\/05\/\u540d\u79f0\u672a\u8a2d\u5b9a\u30d5\u30a1\u30a4\u30eb-1.jpg\" alt=\"\" width=\"557\" height=\"425\" srcset=\"https:\/\/www.ecomottblog.com\/wp-content\/uploads\/2025\/05\/\u540d\u79f0\u672a\u8a2d\u5b9a\u30d5\u30a1\u30a4\u30eb-1.jpg 557w, https:\/\/www.ecomottblog.com\/wp-content\/uploads\/2025\/05\/\u540d\u79f0\u672a\u8a2d\u5b9a\u30d5\u30a1\u30a4\u30eb-1-300x229.jpg 300w, https:\/\/www.ecomottblog.com\/wp-content\/uploads\/2025\/05\/\u540d\u79f0\u672a\u8a2d\u5b9a\u30d5\u30a1\u30a4\u30eb-1-280x214.jpg 280w, https:\/\/www.ecomottblog.com\/wp-content\/uploads\/2025\/05\/\u540d\u79f0\u672a\u8a2d\u5b9a\u30d5\u30a1\u30a4\u30eb-1-282x215.jpg 282w\" sizes=\"(max-width: 557px) 100vw, 557px\" \/>\n\n&nbsp;\n\n\u5b9a\u7fa9\u306f\u4e0b\u8a18\u306e\u901a\u308a\u3067\u3059\u3002\n\u8272\u3005\u66f8\u3044\u3066\u3044\u307e\u3059\u304c\u3001steps\u4ee5\u964d\u306b\u66f8\u304b\u308c\u3066\u3044\u308b\u3053\u3068\u304c\u5b9f\u969b\u306b\u3084\u308a\u305f\u3044\u3053\u3068\u3067\u3001\n\n<ul>\n    <li>\u30bd\u30fc\u30b9\u30b3\u30fc\u30c9\u3092\u30c1\u30a7\u30c3\u30af\u30a2\u30a6\u30c8<\/li>\n    <li>Node.js\u3092\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7<\/li>\n    <li>\u30d1\u30c3\u30b1\u30fc\u30b8\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/li>\n    <li>React\u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u3092\u30d3\u30eb\u30c9<\/li>\n    <li>AWS\u306e\u30af\u30ec\u30c7\u30f3\u30b7\u30e3\u30eb\u53d6\u5f97<\/li>\n    <li>S3\u3078\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9<\/li>\n    <li>CloudFront\u306e\u30ad\u30e3\u30c3\u30b7\u30e5\u524a\u9664<\/li>\n<\/ul>\n\n\u3068\u306a\u3063\u3066\u3044\u307e\u3059\u3002\n\n<pre><code>name: Auto Deploy\n\non:\n&nbsp; pull_request:\n&nbsp; &nbsp; types: [closed]\n&nbsp; &nbsp; branches:\n&nbsp; &nbsp; &nbsp; - develop\n\npermissions:\n&nbsp; contents: read\n&nbsp; id-token: write\n\njobs:\n&nbsp; build_and_deploy:\n&nbsp; &nbsp; if: github.event.pull_request.merged == true\n&nbsp; &nbsp; runs-on: ubuntu-latest\n&nbsp; &nbsp; environment: dev\n&nbsp; &nbsp; env:\n&nbsp; &nbsp; &nbsp; VITE_API_BASE_URL: ${{ vars.VITE_API_BASE_URL}}\n&nbsp; &nbsp; &nbsp; VITE_USE_MSW: ${{ vars.VITE_USE_MSW }}\n&nbsp; &nbsp; &nbsp; AWS_ROLE_ARN: ${{ vars.AWS_ROLE_ARN }}\n&nbsp; &nbsp; &nbsp; AWS_REGION: ${{ vars.AWS_REGION }}\n&nbsp; &nbsp; &nbsp; AWS_TARGET_S3_BUCKET_URL: ${{ vars.AWS_TARGET_S3_BUCKET_URL }}\n&nbsp; &nbsp; &nbsp; AWS_CLOUDFRONT_ID: ${{ vars.AWS_CLOUDFRONT_ID }}\n\n&nbsp; &nbsp; steps:\n&nbsp; &nbsp; &nbsp; - name: Checkout repository\n&nbsp; &nbsp; &nbsp; &nbsp; uses: actions\/checkout@v2\n\n&nbsp; &nbsp; &nbsp; - name: Set up Node.js\n&nbsp; &nbsp; &nbsp; &nbsp; uses: actions\/setup-node@v2\n&nbsp; &nbsp; &nbsp; &nbsp; with:\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; node-version: '18'\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;\n&nbsp; &nbsp; &nbsp; - name: Install dependencies\n&nbsp; &nbsp; &nbsp; &nbsp; run: npm install\n\n&nbsp; &nbsp; &nbsp; - name: Build\n&nbsp; &nbsp; &nbsp; &nbsp; run: npm run build\n\n&nbsp; &nbsp; &nbsp; - name: Set up AWS Credentials\n&nbsp; &nbsp; &nbsp; &nbsp; uses: aws-actions\/configure-aws-credentials@v4\n&nbsp; &nbsp; &nbsp; &nbsp; with:\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; role-session-name: ecomott-blog-cicd\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; role-to-assume: ${{env.AWS_ROLE_ARN}}\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; aws-region: ${{env.AWS_REGION}}\n\n&nbsp; &nbsp; &nbsp; - name: Deploy to S3\n&nbsp; &nbsp; &nbsp; &nbsp; run: |\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; aws s3 sync .\/dist ${{env.AWS_TARGET_S3_BUCKET_URL}} --delete\n\n&nbsp; &nbsp; &nbsp; - name: Invalidate CloudFront Cache\n&nbsp; &nbsp; &nbsp; &nbsp; run: |\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; aws cloudfront create-invalidation --distribution-id ${{env.AWS_CLOUDFRONT_ID}} --paths \"\/*\"\n\n<\/code><\/pre>\n\n&nbsp;\n\n<h2>\u30dd\u30a4\u30f3\u30c8<\/h2>\n\n\u4e0a\u8a18\u306e\u30ef\u30fc\u30af\u30d5\u30ed\u30fc\u306e\u4e2d\u3067\u4e00\u756a\u91cd\u8981\u306a\u30dd\u30a4\u30f3\u30c8\u3067\u3042\u308bS3\u3078\u306e\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u5468\u308a\u306b\u3064\u3044\u3066\u8aac\u660e\u3057\u307e\u3059\u3002 &nbsp;\n\n<h3>\u8a8d\u8a3c<\/h3>\n\n\u8a8d\u8a3c\u3092\u884c\u3063\u3066\u3044\u308b\u90e8\u5206\u306f\u3053\u3053\u3067\u3059\u3002\n\n<pre><code>&nbsp; &nbsp; &nbsp; - name: Set up AWS Credentials\n&nbsp; &nbsp; &nbsp; &nbsp; uses: aws-actions\/configure-aws-credentials@v4\n&nbsp; &nbsp; &nbsp; &nbsp; with:\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; role-session-name: ecomott-blog-cicd\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; role-to-assume: ${{env.AWS_ROLE_ARN}}\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; aws-region: ${{env.AWS_REGION}}\n<\/code><\/pre>\n\n&nbsp;\n\n<p style=\"text-align: left;\">S3\u3092\u69cb\u7bc9\u3059\u308b\u6642\u306b\u3001\u901a\u5e38\u5916\u90e8\u304b\u3089\u306e\u30a2\u30af\u30bb\u30b9\u3092\u8a31\u53ef\u3059\u308b\u3053\u3068\u306f\u63a8\u5968\u3055\u308c\u3066\u3044\u307e\u305b\u3093\u3002\u3053\u306e\u81ea\u52d5\u30c7\u30d7\u30ed\u30a4\u3092\u884c\u3046\u5834\u5408\u306b\u304a\u3044\u3066\u3082\u4f8b\u5916\u3067\u306f\u306a\u304f\u3001\u3053\u306eCI\/CD\u30d7\u30ed\u30bb\u30b9\u306e\u4e2d\u3067\u30af\u30ec\u30c7\u30f3\u30b7\u30e3\u30eb\u3092\u53d6\u5f97\u3057\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002<\/p>\n\n<p style=\"text-align: left;\">\u771f\u3063\u5148\u306b\u601d\u3044\u3064\u304f\u306e\u306f\u3001IAM\u306e\u30a2\u30af\u30bb\u30b9\u30ad\u30fc\u3001\u30b7\u30fc\u30af\u30ec\u30c3\u30c8\u30ad\u30fc\u3092\u4f7f\u3046\u65b9\u6cd5\u3067\u3059\u304c\u3001AWS\u306e\u304a\u4f5c\u6cd5\u3068\u3057\u3066\u3053\u308c\u3089\u3092\u4f7f\u3046\u3053\u3068\u306f\u63a8\u5968\u3055\u308c\u3066\u3044\u307e\u305b\u3093\u3002<\/p>\n\n<p style=\"text-align: left;\">\u305d\u3093\u306a\u60a9\u307f\u3092\u89e3\u6c7a\u3059\u308b\u4ee3\u66ff\u6848\u304c\u3001<strong> uses: aws-actions\/configure-aws-credentials@v4<\/strong> \u3067\u3059\u3002\uff08<a href=\"https:\/\/github.com\/aws-actions\/configure-aws-credentials\">GitHub &#8211; aws-actions\/configure-aws-credentials: Configure AWS credential environment variables for use in other GitHub Actions.<\/a>\uff09<\/p>\n\n<p style=\"text-align: left;\">\u3053\u306euses\u306f\u7b2c\u4e09\u8005\u304c\u7528\u610f\u3057\u305f\u30a2\u30af\u30b7\u30e7\u30f3\u3092\u5229\u7528\u3059\u308b\u305f\u3081\u306e\u30c7\u30a3\u30ec\u30af\u30c6\u30a3\u30d6\u3067\u3001<code>aws-actions\/configure-aws-credentials@v4<\/code>\u306f\u3001AWS\u304c\u516c\u5f0f\u306b\u958b\u767a\u3057\u3066\u3044\u308b\u3001GitHub Actions\u5185\u3067Assume Role\u3092\u7c21\u5358\u306b\u5b9f\u73fe\u3059\u308b\u305f\u3081\u306e\u6a5f\u80fd\u3092\u305d\u308d\u3048\u305f\u3082\u306e\u306b\u306a\u3063\u3066\u3044\u307e\u3059\u3002<\/p>\n\n<p style=\"text-align: left;\">\u3053\u308c\u3092\u4f7f\u3046\u3053\u3068\u3067\u4f55\u304c\u5b09\u3057\u3044\u306e\u304b\u306b\u3064\u3044\u3066\u306e\u30d2\u30f3\u30c8\u304c\u4e0a\u8a18\u30ef\u30fc\u30af\u30d5\u30ed\u30fc\u306e<code>env<\/code>\u306b\u3042\u308a\u307e\u3059\u3002<code>AWS_<\/code>\u304b\u3089\u59cb\u307e\u308b\u5024\u304b\u3089\u4f55\u3068\u306a\u304f\u5bdf\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u308b\u304b\u3068\u601d\u3044\u307e\u3059\u304c\u3001\u3053\u306e\u30ef\u30fc\u30af\u30d5\u30ed\u30fc\u306e\u8a2d\u5b9a\u3067\u306f\u3001\u8a8d\u8a3c\u3092\u53d6\u5f97\u3059\u308b\u305f\u3081\u306e\u30b7\u30fc\u30af\u30ec\u30c3\u30c8\u60c5\u5831\u304c\u4e0d\u8981\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n\n<p style=\"text-align: left;\">\u5229\u7528\u3059\u308b\u306b\u306fAWS\u4e0a\u3067ID\u30d7\u30ed\u30d0\u30a4\u30c0\u3092\u8a2d\u5b9a\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002\u8aac\u660e\u304c\u9577\u304f\u306a\u308b\u306e\u3067\u7d39\u4ecb\u306f\u7701\u7565\u3057\u307e\u3059\u304c\u3001\u8a73\u3057\u304f\u306fGitHub\u306e\u3053\u306e\u8a18\u4e8b\u3092\u53c2\u8003\u306b\u3057\u3066\u304f\u3060\u3055\u3044\u3002<a href=\"https:\/\/docs.github.com\/en\/actions\/security-for-github-actions\/security-hardening-your-deployments\/configuring-openid-connect-in-amazon-web-services\">Configuring OpenID Connect in Amazon Web Services &#8211; GitHub Docs<\/a><\/p>\n\n<h3>\u30ad\u30e3\u30c3\u30b7\u30e5\u306e\u30af\u30ea\u30a2<\/h3>\n\n<pre><code>&nbsp; &nbsp; &nbsp; - name: Invalidate CloudFront Cache\n&nbsp; &nbsp; &nbsp; &nbsp; run: |\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; aws cloudfront create-invalidation --distribution-id ${{env.AWS_CLOUDFRONT_ID}} --paths \"\/*\"\n<\/code><\/pre>\n\n&nbsp;\n\n\u624b\u52d5\u3067\u306e\u4f5c\u696d\u3067\u3088\u304f\u5fd8\u308c\u3066\u3057\u307e\u3046\u306e\u304cCloudFront\u306e\u30ad\u30e3\u30c3\u30b7\u30e5\u30af\u30ea\u30a2\u3067\u3059\u3002\u3059\u3050\u306b\u3067\u304d\u308b\u306e\u3067\u3059\u304c\u3001\u5730\u5473\u306b\u9762\u5012\u306a\u306e\u3067\u3053\u308c\u3082\u30ef\u30fc\u30af\u30d5\u30ed\u30fc\u3067\u5b9a\u7fa9\u3057\u307e\u3057\u305f\u3002 run\u3092\u898b\u3066\u308f\u304b\u308b\u901a\u308a\u3001aws cli\u306e\u30b3\u30de\u30f3\u30c9\u3092\u5b9f\u884c\u3057\u3066\u3044\u308b\u3060\u3051\u3067\u3059\u306d\u3002\u305f\u3063\u305f\u3053\u308c\u3060\u3051\u3067\u81ea\u52d5\u3067\u30af\u30ea\u30a2\u3067\u304d\u308b\u306e\u3067\u975e\u5e38\u306b\u697d\u3067\u3059\u3002\n\n<h3>\u30ed\u30fc\u30eb\u306a\u3069\u306e\u8aac\u660e<\/h3>\n\n\u6700\u5f8c\u306b\u5fc5\u8981\u306b\u306a\u308b\u30ed\u30fc\u30eb\u306e\u8a2d\u5b9a\u3092\u7d39\u4ecb\u3057\u3066\u7d42\u308f\u308d\u3046\u3068\u601d\u3044\u307e\u3059\u3002 \u5fc5\u8981\u306b\u306a\u308b\u306e\u306f1\u3064\u306e\u30ed\u30fc\u30eb\u3067\u3059\u304c\u3001\u4fe1\u983c\u30dd\u30ea\u30b7\u30fc\u3068IAM\u30dd\u30ea\u30b7\u30fc\u306e2\u3064\u3092\u8a2d\u5b9a\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002 \u307e\u305a\u306f\u4fe1\u983c\u30dd\u30ea\u30b7\u30fc\u3067\u3059\u3002OIDC\u30d7\u30ed\u30d0\u30a4\u30c0\u30fc\u3068\u306e\u4fe1\u983c\u30dd\u30ea\u30b7\u30fc\u306b\u306a\u308a\u307e\u3059\u3002\n\n<div>\n<pre class=\"\">{\n\n  &nbsp; \"Version\": \"2012-10-17\",\n  &nbsp; \"Statement\": [\n  &nbsp; &nbsp; &nbsp; {\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"Sid\": \"\",\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"Effect\": \"Allow\",\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"Principal\": {\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"Federated\": \"arn:aws:iam::&lt;\u30a2\u30ab\u30a6\u30f3\u30c8ID&gt;:oidc-provider\/token.actions.githubusercontent.com\"\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; },\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"Action\": \"sts:AssumeRoleWithWebIdentity\",\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"Condition\": {\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"StringEquals\": {\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"token.actions.githubusercontent.com:aud\": \"sts.amazonaws.com\"\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; },\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"StringLike\": {\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"token.actions.githubusercontent.com:sub\": \"&lt;GitHub\u30e6\u30fc\u30b6\u30fc\u540d\u307e\u305f\u306f\u7d44\u7e54\u540d&gt;\/&lt;\u30ea\u30dd\u30b8\u30c8\u30ea\u540d&gt;:*\"\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }\n  &nbsp; &nbsp; &nbsp; }\n  &nbsp; ]\n}<\/pre>\n<\/div>\n\n\u6b21\u306bIAM\u30dd\u30ea\u30b7\u30fc\u3067\u3059\u3002\u5bfe\u8c61\u3092\u5236\u9650\u3057\u3066\u3044\u307e\u3059\u3002\n\n<div>\n<pre class=\"\">{\n  &nbsp; \"Version\": \"2012-10-17\",\n  &nbsp; \"Statement\": [\n  &nbsp; &nbsp; &nbsp; {\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"Effect\": \"Allow\",\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"Action\": [\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"s3:PutObject\",\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"s3:ListBucket\",\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"s3:DeleteObject\"\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ],\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"Resource\": [\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"arn:aws:s3:::&lt;s3\u30d0\u30b1\u30c3\u30c8\u540d&gt;\",\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"arn:aws:s3:::&lt;s3\u30d0\u30b1\u30c3\u30c8\u540d&gt;\/*\",\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ]\n  &nbsp; &nbsp; &nbsp; },\n  &nbsp; &nbsp; &nbsp; {\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"Effect\": \"Allow\",\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"Action\": [\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"cloudfront:CreateInvalidation\"\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ],\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"Resource\": [\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"arn:aws:cloudfront::&lt;\u30a2\u30ab\u30a6\u30f3\u30c8ID&gt;:distribution\/&lt;CloudFront\u30c7\u30a3\u30b9\u30c8\u30ea\u30d3\u30e5\u30fc\u30b7\u30e7\u30f3ID&gt;\"\n  &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ]\n  &nbsp; &nbsp; &nbsp; }\n  &nbsp; ]\n}<\/pre>\n<\/div>\n\n\u3053\u308c\u3067\u4f5c\u6210\u3067\u304d\u305fIAM\u30ed\u30fc\u30eb\u306eARN\u3092GitHub Actions\u3067\u5229\u7528\u3057\u307e\u3059\u3002\n\n<h2>\u6700\u5f8c\u306b<\/h2>\n\n<p style=\"text-align: left;\">\u307e\u3060\u30c6\u30b9\u30c8\u304c\u5145\u5b9f\u3057\u3066\u3044\u306a\u3044\u306e\u3067\u7701\u7565\u3057\u307e\u3057\u305f\u304c\u3001\u81ea\u52d5\u30c6\u30b9\u30c8\u7b49\u3082\u81ea\u52d5\u5316\u3067\u304d\u3066\u3057\u307e\u3044\u307e\u3059\u3002\n\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u304c\u9032\u3080\u306b\u3064\u308c\u3066\u5145\u5b9f\u3055\u305b\u3066\u3044\u304d\u305f\u3044\u3067\u3059\u304c\u3001\u5c11\u3057\u305a\u3064\u53d6\u308a\u5165\u308c\u3066\u3044\u304f\u4eca\u306e\u30a2\u30d7\u30ed\u30fc\u30c1\u3067\u3082\u30e1\u30ea\u30c3\u30c8\u304c\u304b\u306a\u308a\u5927\u304d\u3044\u306a\u3068\u601d\u3044\u307e\u3057\u305f\u3002<\/p>\n\n<p style=\"text-align: left;\">\u30a8\u30b3\u30e2\u30c3\u30c8\u3067\u306f\u4e00\u7dd2\u306b\u30e2\u30ce\u3065\u304f\u308a\u3092\u3057\u3066\u3044\u304f\u4ef2\u9593\u3092\u52df\u96c6\u4e2d\u3067\u3059\u3002\u5f0a\u793e\u306b\u5c11\u3057\u3067\u3082\u8208\u5473\u304c\u3042\u308b\u65b9\u3001AWS\u3092\u4f7f\u3063\u305f\u958b\u767a\u306b\u8208\u5473\u304c\u3042\u308b\u65b9\u306f\u305c\u3072\u4e0b\u8a18\u306e\u63a1\u7528\u30da\u30fc\u30b8\u3092\u3054\u89a7\u304f\u3060\u3055\u3044\uff01<\/p>\n\n<!-- \/wp:paragraph -->\n\n<!-- wp:list -->\n\n<ul>\n    <li style=\"list-style-type: none;\">\n<ul><!-- wp:list-item --><\/ul>\n<\/li>\n<\/ul>\n\n<!-- \/wp:list-item -->\n\n<!-- wp:list-item -->\n\n<ul>\n    <li><a href=\"https:\/\/www.wantedly.com\/companies\/ecomott2\/projects\">Wantedly<\/a><\/li>\n    <li><a href=\"https:\/\/www.ecomott.co.jp\/recruit\/?__hstc=42779642.a8c8704dec326b3c77f9ee44861aff6e.1716777314693.1721088108443.1721176219041.17&amp;__hssc=42779642.1.1721176219041&amp;__hsfp=241943720\">\u52df\u96c6\u8981\u9805\uff08\u5f53\u793eHP\uff09<\/a><\/li>\n<\/ul>","protected":false},"excerpt":{"rendered":"<p>\u3053\u3093\u306b\u3061\u306f\uff01\u30af\u30e9\u30a6\u30c9\u30bd\u30ea\u30e5\u30fc\u30b7\u30e7\u30f3\u958b\u767a\u90e8\u306e\u897f\u8c37\u3067\u3059\u3002GitHub Actions\u3092\u4f7f\u3063\u3066React\u3067\u5b9f\u88c5\u3057\u305f\u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u3092AWS\u74b0\u5883\u3078\u81ea\u52d5\u30c7\u30d7\u30ed\u30a4\u8a2d\u5b9a\u3057\u3001\u696d\u52d9\u52b9\u7387\u3092\u5411\u4e0a\u3055\u305b\u307e\u3057\u305f\u3002\u624b\u8efd\u306b\u5b9f\u8df5\u3067\u304d\u308b\u306e\u3067\u60c5\u5831\u3092\u30b7\u30a7\u30a2\u3057\u307e [&hellip;]<\/p>\n","protected":false},"author":105,"featured_media":17353,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[27],"tags":[24,167,171,301],"_links":{"self":[{"href":"https:\/\/www.ecomottblog.com\/index.php?rest_route=\/wp\/v2\/posts\/17326"}],"collection":[{"href":"https:\/\/www.ecomottblog.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.ecomottblog.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.ecomottblog.com\/index.php?rest_route=\/wp\/v2\/users\/105"}],"replies":[{"embeddable":true,"href":"https:\/\/www.ecomottblog.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=17326"}],"version-history":[{"count":89,"href":"https:\/\/www.ecomottblog.com\/index.php?rest_route=\/wp\/v2\/posts\/17326\/revisions"}],"predecessor-version":[{"id":20400,"href":"https:\/\/www.ecomottblog.com\/index.php?rest_route=\/wp\/v2\/posts\/17326\/revisions\/20400"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.ecomottblog.com\/index.php?rest_route=\/wp\/v2\/media\/17353"}],"wp:attachment":[{"href":"https:\/\/www.ecomottblog.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=17326"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.ecomottblog.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=17326"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.ecomottblog.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=17326"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}