Forked from jjruescas/install_choco_and_packages.ps1
Created
December 12, 2022 15:52
-
-
Save dannybarrientos/1a59899e904aac2be7f5c1197bc38a87 to your computer and use it in GitHub Desktop.
Revisions
-
jjruescas revised this gist
Jan 1, 2020 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -3,7 +3,7 @@ provider "aws" { } resource "aws_security_group" "instance" { name = "terraform-example-sg" ingress { from_port = 80 -
jjruescas revised this gist
Dec 31, 2019 . No changes.There are no files selected for viewing
-
jjruescas revised this gist
Dec 31, 2019 . No changes.There are no files selected for viewing
-
jjruescas created this gist
Dec 31, 2019 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,9 @@ #Install Chocolatey Set-ExecutionPolicy Bypass -Scope Process -Force; iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1')) #Install Packages choco install terraform -y choco install awscli -y #Refresh Environment Variables $env:Path = [System.Environment]::GetEnvironmentVariable("Path","Machine") This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,37 @@ provider "aws" { region = "us-west-2" } resource "aws_security_group" "instance" { name = "terraform-example-instance" ingress { from_port = 80 to_port = 80 protocol = "tcp" cidr_blocks = ["0.0.0.0/0"] } egress { from_port = 0 to_port = 0 protocol = "-1" cidr_blocks = ["0.0.0.0/0"] } } resource "aws_instance" "web" { ami = "ami-0c5204531f799e0c6" instance_type = "t2.micro" vpc_security_group_ids = [aws_security_group.instance.id] user_data = <<-EOF #!/bin/bash sudo amazon-linux-extras install nginx1.12 -y sudo service nginx start EOF tags = { Name = "HelloWorld" } } This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,3 @@ output "public_ip" { value = "${aws_instance.web.public_ip}" }