Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/gforien/create-aws-website
DΓ©ployer en quelques secondes un site Web avec configuration NGINX et DNS π¨βπ»π
https://github.com/gforien/create-aws-website
aws aws-cli aws-ec2 powershell powershell-core pwsh
Last synced: about 7 hours ago
JSON representation
DΓ©ployer en quelques secondes un site Web avec configuration NGINX et DNS π¨βπ»π
- Host: GitHub
- URL: https://github.com/gforien/create-aws-website
- Owner: gforien
- Created: 2021-11-03T02:31:47.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2021-12-14T13:33:02.000Z (almost 3 years ago)
- Last Synced: 2024-09-19T04:55:51.412Z (6 days ago)
- Topics: aws, aws-cli, aws-ec2, powershell, powershell-core, pwsh
- Language: PowerShell
- Homepage:
- Size: 314 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# create-aws-website
### Launch an EC2 instance with NGINX and DNS configuration in a few seconds β‘Requires [aws-cli](https://aws.amazon.com/cli) and a few environment variables corresponding to AWS resources:
| | |
|-----------------------------|---------------------------------------------------------------------------------------------|
| `$AWS_KEYNAME` | the **name** of a pre-existing AWS SSH key |
| `$AWS_HTTPS_SECURITY_GROUP` | the **name** of a security group in the default VPC, with open port 80 (and 443 optionnaly) |
| `$AWS_ZONE` | the ID of a pre-existing DNS zone (ex: Z00859AK9X732H) |### π·ββοΈ Launch with Terraform
```powershell
cd terraform/
terraform plan `
-var "key=$AWS_KEYNAME" `
-var "sg=$AWS_HTTPS_SECURITY_GROUP" `
-var "zone=$AWS_ZONE" `
-var "target=babasr.aws.gforien.com"
terraform apply -auto-approve `
-var "key=$AWS_KEYNAME" `
-var "sg=$AWS_HTTPS_SECURITY_GROUP" `
-var "zone=$AWS_ZONE" `
-var "target=babasr.aws.gforien.com"
```### π·ββοΈ Launch with a hand-made Powershell script
```powershell
cd powershell/
# dot-source the wrapper script
. ./script.ps1# execute
Create-AWS-Website babasr.aws.gforien.com
```
![](./screenshot.jpg)### β¨ Result
![](./result.png)#### Gabriel Forien
INSA Lyon