This configuration shows a deployment on cloud.ca with:
- a web network
- a database network
- a tools network
The number of web instances and database instances is configurable.
If the environment is intended to be for production workloads, set the
variable is_production
to true and the ACLs for the networks will be
more strict:
- SSH access is allowed only from the instance in the tools network (except for the tools instance itself)
- The database port is blocked on the database network, except for the IPs of the web instances
- generate ssh keys, with
ssh-keygen -t rsa -b 4096 -N "" -f ./id_rsa
for example - create a file terraform.tfvars containing at least the following variables:
api_key
: your cloud.ca API keyorganization_code
: name used to connect to cloud.ca - <organization_code>.cloud.caservice_code
:compute-qc
orcompute-on
environment_name
: production, dev for exampleadmin
: a list of users in your organization who will have theEnvironment Admin
roleread_only
: a list of users in your organization who wil have theRead Only
rolefrontend_count
: number of instances in the web networkbackend_count
: number of instances in the database networkis_production
: set to true for production, false otherwise