Description | |
---|---|
Ether | Ethereum's cryptocurrency is called Ether (ETH). It is the fuel that keeps the network running. It is used to pay for the computational resources and transaction fees associated with each transaction carried out on the Ethereum network. |
Smart Contracts | A smart contract is a simple computer program that facilitates the exchange of any asset between two parties. |
Ethereum Virtual Machine | Ethereum provides the underlying technology, architecture, and software to understand smart contracts and interact with them. |
Decentralized applications (Dapps) | A Dapp is like any other piece of software you use. It might be a mobile app or a website. A Dapp is an application that is built on a decentralized network, such as Ethereum, as opposed to a conventional app |
This file contains 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 characters
... | |
resource "aws_instance" "dev-node" { | |
count = "${var.nodes_count}" // Declare it in variables.tf | |
ami = "${data.aws_ami.ubuntu.id}" | |
instance_type = "t2.micro" | |
key_name = "${aws_key_pair.aws_dev_key.key_name}" | |
security_groups = [ | |
"${aws_security_group.allow_all.name}", | |
] |
This file contains 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 characters
... | |
resource "aws_security_group" "allow_all" { | |
name = "allow_all" | |
description = "Allow all traffic" | |
ingress { | |
from_port = 0 | |
to_port = 0 | |
protocol = "-1" | |
cidr_blocks = ["0.0.0.0/0"] |
This file contains 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 characters
... | |
resource "aws_route_table_association" "main-{{ name }}" { | |
subnet_id = "${aws_subnet.main-{{ name }}.id}" | |
route_table_id = "${aws_route_table.main-{{ name }}.id}" | |
} |
This file contains 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 characters
... | |
resource "aws_vpc" "main-{{ name }}" { | |
cidr_block = "172.26.0.0/16" | |
enable_dns_hostnames = true | |
enable_dns_support = true | |
tags = { |
This file contains 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 characters
resource "aws_key_pair" "key-{{ name }}" { | |
key_name = "{{ name }}" public_key = var.public_key | |
} |
This file contains 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 characters
provider "aws" { | |
region = var.location | |
version = "~>2.28" | |
} |
This file contains 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 characters
output "ip_address" { | |
value = "${aws_instance.main-{{ name }}.*.public_ip} | |
} |
This file contains 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 characters
terraform { | |
required_version = ">= 0.12" | |
} |
This file contains 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 characters
resource "aws_s3_bucket" "terraform_state" { | |
bucket = "bucket name" | |
versioning { | |
enabled = true | |
} | |
# lifecycle { | |
# prevent_destroy = true | |
# } |