Skip to content

Instantly share code, notes, and snippets.

@selutin99
Last active March 21, 2022 06:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save selutin99/db62633923de8db724829700fed3af7a to your computer and use it in GitHub Desktop.
Save selutin99/db62633923de8db724829700fed3af7a to your computer and use it in GitHub Desktop.
CI/CD via Github Actions and AWS
server {
listen 80;
location /static {
alias /home/ec2-user/app/static;
}
location / {
proxy_set_header Host $http_host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_pass http://localhost:5000;
proxy_redirect off;
}
}
{
"Description": "AWS CloudFormation stack for RDS creation",
"Parameters": {
"MySQLUser": {
"Type": "String"
},
"MySQLPassword": {
"Type": "String"
},
"MySQLSchemaName": {
"Type": "String"
}
},
"Resources": {
"Database": {
"Type": "AWS::RDS::DBInstance",
"Properties": {
"DBInstanceIdentifier": {
"Ref": "MySQLSchemaName"
},
"DBInstanceClass": "db.t2.micro",
"AllocatedStorage": "20",
"Engine": "MySQL",
"EngineVersion": "8.0.21",
"PubliclyAccessible": "true",
"MasterUsername": {
"Ref": "MySQLUser"
},
"MasterUserPassword": {
"Ref": "MySQLPassword"
},
"Port": "3306"
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment