Skip to content
Merged
Show file tree
Hide file tree
Changes from 41 commits
Commits
Show all changes
50 commits
Select commit Hold shift + click to select a range
c91e2eb
[OSDEV-899] Move React application to the S3 bucket
roninzp Dec 10, 2024
0c90d10
Merge branch 'main' into OSDEV-899/move-react-to-s3
roninzp Dec 10, 2024
261a1f4
Merge branch 'main' into OSDEV-899/move-react-to-s3
roninzp Dec 12, 2024
5f04854
Merge branch 'main' into OSDEV-899/move-react-to-s3
roninzp Dec 13, 2024
0a7a8de
Merge branch 'main' into OSDEV-899/move-react-to-s3
roninzp Dec 13, 2024
149d104
[OSDEV-899] Move React application to the S3 bucket
roninzp Dec 13, 2024
b4cdf8f
Merge branch 'main' into OSDEV-899/move-react-to-s3
roninzp Dec 18, 2024
3c8d541
Merge branch 'main' into OSDEV-899/move-react-to-s3
roninzp Jan 14, 2025
13f76e3
S3 bucket policy
roninzp Jan 15, 2025
dedb4c8
BucketOwnerEnforced
roninzp Jan 15, 2025
4f27a61
Fix S3 sync
roninzp Jan 15, 2025
ab11284
config CloudFront
roninzp Jan 15, 2025
db2139f
config CloudFront
roninzp Jan 15, 2025
22d4d5b
config CloudFront
roninzp Jan 15, 2025
92a339f
config CloudFront
roninzp Jan 15, 2025
299f4c8
config CloudFront
roninzp Jan 15, 2025
2a583d4
config CloudFront
roninzp Jan 15, 2025
097f65a
config CloudFront
roninzp Jan 15, 2025
a028a7f
config CloudFront
roninzp Jan 15, 2025
11990ca
added behavior /auth/login
roninzp Jan 15, 2025
c80c17a
additional behaviors
roninzp Jan 16, 2025
3d5a0a5
Fully disabled versioning for React S3 bucket
roninzp Jan 16, 2025
c2b3ae1
This React endpoints
roninzp Jan 17, 2025
8c38d35
Merge branch 'main' into OSDEV-899/move-react-to-s3
roninzp Jan 20, 2025
13f1109
disable set acl
roninzp Jan 20, 2025
79b6eef
disable set acl
roninzp Jan 20, 2025
7cee0a7
disable set acl
roninzp Jan 20, 2025
cdfe708
Merge branch 'main' into OSDEV-899/move-react-to-s3
roninzp Jan 20, 2025
bb8d3cf
Merge branch 'main' into OSDEV-899/move-react-to-s3
roninzp Jan 21, 2025
45016e1
React app deleted from Django container
roninzp Jan 21, 2025
c9db335
Merge branch 'main' into OSDEV-899/move-react-to-s3
roninzp Jan 21, 2025
b720bb2
React app deleted from Django container
roninzp Jan 21, 2025
7f14163
React app deleted from Django container
roninzp Jan 21, 2025
b07b14c
Forward /static/* to S3 origin
roninzp Jan 21, 2025
5a29d6e
Release notes
roninzp Jan 21, 2025
7a946c1
Additional traffic rules for Django
roninzp Jan 21, 2025
343916f
Merge branch 'main' into OSDEV-899/move-react-to-s3
roninzp Jan 23, 2025
461d2da
removed comments
roninzp Jan 29, 2025
3f061d1
Merge branch 'main' into OSDEV-899/move-react-to-s3
roninzp Jan 29, 2025
224420d
Merge branch 'main' into OSDEV-899/move-react-to-s3
roninzp Jan 29, 2025
f063bad
Merge branch 'main' into OSDEV-899/move-react-to-s3
roninzp Jan 29, 2025
77d9e27
Merge branch 'main' into OSDEV-899/move-react-to-s3
vladsha-dev Jan 31, 2025
60ba487
Merge branch 'main' into OSDEV-899/move-react-to-s3
roninzp Feb 3, 2025
f4254ea
Move task to the next release
roninzp Feb 3, 2025
866a16a
Resolve conversations
roninzp Feb 3, 2025
0b72213
Merge branch 'main' into OSDEV-899/move-react-to-s3
roninzp Feb 4, 2025
db6c434
Resolve conversations
roninzp Feb 4, 2025
59e627a
Resolve conversations
roninzp Feb 5, 2025
c9920db
Merge branch 'main' into OSDEV-899/move-react-to-s3
vladsha-dev Feb 5, 2025
eaa5929
Change release version
roninzp Feb 6, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 21 additions & 1 deletion .github/workflows/deploy_to_aws.yml
Original file line number Diff line number Diff line change
Expand Up @@ -156,8 +156,28 @@ jobs:
working-directory: src/react
run: yarn run build

- id: project
uses: Entepotenz/change-string-case-action-min-dependencies@v1
with:
string: ${{ vars.PROJECT }}

- name: Move static
run: mv src/react/build src/django/static
env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
FRONTEND_BUCKET: ${{ steps.project.outputs.lowercase }}-${{ steps.get_env_name.outputs.lowercase }}-frontend
AWS_DEFAULT_REGION: "eu-west-1"
CLOUDFRONT_DOMAIN: ${{ vars.CLOUDFRONT_DOMAIN }}
run: |
for id in $(aws cloudfront list-distributions --query "DistributionList.Items[*].Id" --output text); do
domains=$(aws cloudfront get-distribution-config --id $id --query "DistributionConfig.Aliases.Items" --output text)
if [[ "$domains" == "$CLOUDFRONT_DOMAIN" ]]; then
echo "Found Distribution ID: $id for Domain: $CLOUDFRONT_DOMAIN"
CLOUDFRONT_DISTRIBUTION_ID=$id
fi
done
aws s3 sync src/react/build/ s3://$FRONTEND_BUCKET-$AWS_DEFAULT_REGION/ --delete
aws cloudfront create-invalidation --distribution-id $CLOUDFRONT_DISTRIBUTION_ID --paths "/*"

- name: Configure AWS credentials for ${{ vars.ENV_NAME }}
uses: aws-actions/configure-aws-credentials@v1
Expand Down
Loading