Skip to content
Browse files

Terraform updating

  • Loading branch information...
naviat committed Nov 16, 2018
1 parent e076907 commit 04db0344344674630ea4412649bb4b113c6cb3da
Showing with 106 additions and 0 deletions.
  1. +31 −0 .gitignore
  2. +6 −0 .pre-commit-config.yaml
  3. +69 −0
@@ -0,0 +1,31 @@
# Local .terraform directories

# .tfstate files

# Crash log files

# Ignore any .tfvars files that are generated automatically for each Terraform run. Most
# .tfvars files are managed as part of configuration and so should be included in
# version control.
# example.tfvars

# Ignore override files as they are usually used to override resources locally and so
# are not checked in
@@ -0,0 +1,6 @@
- repo: git://
rev: v1.7.3
- id: terraform_fmt
- id: terraform_docs
@@ -0,0 +1,69 @@
# Step-by-step to provision infrastructure of masternodes on AWS EC2

## Updating...

1. Preparation

- Download and install `terraform` following this [docs](

- Config your AWS credentials following this [docs](

1. Configuration

Update `main.tfvars` file at below fields:

- "sshKeyName": specify your ssh key registered on AWS
- "privateKeyPath": path to the private ssh key on your machine
- "coinbasePrivateKeySun": private key of the SUN masternode
- "access_key": AWS access key ID
- "secret_key": AWS secret key

1. Initialization your terraform configuration

The first command to run for a new configuration -- or after checking out an existing configuration from version control -- is terraform init, which initializes various local settings and data that will be used by subsequent commands.

$ terraform init
Initializing the backend...
Initializing provider plugins...
- downloading plugin for provider "aws"...
The following providers do not have any version constraints in configuration,
so the latest version was installed.
To prevent automatic upgrades to new major versions that may contain breaking
changes, it is recommended to add version = "..." constraints to the
corresponding provider blocks in configuration, with the constraint strings
suggested below.
* version = "~> 1.0"
Terraform has been successfully initialized!
You may now begin working with Terraform. Try running "terraform plan" to see
any changes that are required for your infrastructure. All Terraform commands
should now work.
If you ever set or change modules or backend configuration for Terraform,
rerun this command to reinitialize your environment. If you forget, other
commands will detect it and remind you to do so if necessary.

1. Start up SUN masternode, which is included TomoMaster, TomoScan, Netstats

$ terraform plan
$ terraform apply

1. Start up other masternodes

## Bring down

## Vote for a masternode

0 comments on commit 04db034

Please sign in to comment.
You can’t perform that action at this time.