This set of Templates provide all the components to deploy a single Gerrit master in ECS
Two templates are provided in this example:
cf-cluster
: define the ECS cluster and the networking stackcf-service
: defined the service stack running Gerriterror_log
is exported in a Log Group in CloudWatchaws ec2 create-key-pair --key-name gerrit-cluster-keys
NOTE: the EC2 key pair are useful when you need to connect to the EC2 instances for troubleshooting purposes. Store them in a pem
file to use when ssh-ing into your instances as follow: ssh -i yourKeyPairs.pem <ec2_instance_ip>
make create-all
By default the cluster and service name are called, respectively, cluster-stack
and service-stack
. If you want to change the name you can do it by overriding the Makefile parameters:
make create-all CLUSTER_STACK_NAME=my-cluster-stack SERVICE_STACK_NAME=my-service-stack
Keep in mind you will have to pass the same parameters when deleting the stacks.
make delete-all
You can find the Gerrit public URL by running the following command:
aws cloudformation describe-stacks --stack-name gerrit-service
In the Outputs
section the URL is set in the PublicLoadBalancerUrl
key:
"Outputs": [ { "OutputKey": "PublicLoadBalancerUrl", "OutputValue": "http://gerri-LoadB-1CDG276QVT8K8-e28c5bca2e024135.elb.us-east-2.amazonaws.com", "Description": "The url of the external load balancer", "ExportName": "gerrit-ponch-service:PublicLoadBalancerUrl" } ],
The available ports are 8080
for HTTP and 29418
for SSH