Jira AWS Add/Remove Nodes

Add/Remove nodes via AWS Console

Login and navigate to the CloudFormation Stacks page.

Add nodes via AWS CLI

aws cloudformation describe-stacks --output yaml | grep StackName

To help identify your stack name if you don't remember it

mystack=mystackname

ClusterNodeMin=2

ClusterNodeMax=2

Set variables

aws cloudformation describe-stacks --stack-name ${mystack}

Parameter list was correct on 13-Jul-2020; newer versions of the Quick Start may affect the parameter list

aws cloudformation update-stack --stack-name ${mystack} --use-previous-template --parameters \

   ParameterKey=ClusterNodeMin,ParameterValue=${ClusterNodeMin} \

   ParameterKey=ClusterNodeMax,ParameterValue=${ClusterNodeMax} \

   ParameterKey=JiraProduct,UsePreviousValue=true \

   ParameterKey=JiraVersion,UsePreviousValue=true \

   ParameterKey=PrivateSubnet2CIDR,UsePreviousValue=true \

   ParameterKey=TomcatEnableLookups,UsePreviousValue=true \

   ParameterKey=DBIops,UsePreviousValue=true \

   ParameterKey=SSLCertificateARN,UsePreviousValue=true \

   ParameterKey=QSS3KeyPrefix,UsePreviousValue=true \

   ParameterKey=TomcatMinSpareThreads,UsePreviousValue=true \

   ParameterKey=DBMaxWaitMillis,UsePreviousValue=true \

   ParameterKey=DBStorageEncrypted,UsePreviousValue=true \

   ParameterKey=BastionHostRequired,UsePreviousValue=true \

   ParameterKey=DBTestOnBorrow,UsePreviousValue=true \

   ParameterKey=VPCCIDR,UsePreviousValue=true \

   ParameterKey=DeploymentAutomationPlaybook,UsePreviousValue=true \

   ParameterKey=PublicSubnet1CIDR,UsePreviousValue=true \

   ParameterKey=MailEnabled,UsePreviousValue=true \

   ParameterKey=DBMultiAZ,UsePreviousValue=true \

   ParameterKey=JvmHeapOverride,UsePreviousValue=true \

   ParameterKey=QSS3BucketName,UsePreviousValue=true \

   ParameterKey=DBRemoveAbandoned,UsePreviousValue=true \

   ParameterKey=DBInstanceClass,UsePreviousValue=true \

   ParameterKey=DBMasterUserPassword,UsePreviousValue=true \

   ParameterKey=CloudWatchIntegration,UsePreviousValue=true \

   ParameterKey=ClusterNodeInstanceType,UsePreviousValue=true \

   ParameterKey=DBMinIdle,UsePreviousValue=true \

   ParameterKey=PublicSubnet2CIDR,UsePreviousValue=true \

   ParameterKey=DBPassword,UsePreviousValue=true \

   ParameterKey=DeploymentAutomationCustomParams,UsePreviousValue=true \

   ParameterKey=DBStorage,UsePreviousValue=true \

   ParameterKey=TomcatMaxThreads,UsePreviousValue=true \

   ParameterKey=InternetFacingLoadBalancer,UsePreviousValue=true \

   ParameterKey=DeploymentAutomationBranch,UsePreviousValue=true \

   ParameterKey=DBMaxIdle,UsePreviousValue=true \

   ParameterKey=TomcatAcceptCount,UsePreviousValue=true \

   ParameterKey=DBStorageType,UsePreviousValue=true \

   ParameterKey=DBEngine,UsePreviousValue=true \

   ParameterKey=AccessCIDR,UsePreviousValue=true \

   ParameterKey=TomcatDefaultConnectorPort,UsePreviousValue=true \

   ParameterKey=DBMinEvictableIdleTimeMillis,UsePreviousValue=true \

   ParameterKey=DeploymentAutomationKeyName,UsePreviousValue=true \

   ParameterKey=TomcatRedirectPort,UsePreviousValue=true \

   ParameterKey=DBTestWhileIdle,UsePreviousValue=true \

   ParameterKey=HostedZone,UsePreviousValue=true \

   ParameterKey=CatalinaOpts,UsePreviousValue=true \

   ParameterKey=KeyPairName,UsePreviousValue=true \

   ParameterKey=CustomDnsName,UsePreviousValue=true \

   ParameterKey=AvailabilityZones,UsePreviousValue=true \

   ParameterKey=TomcatContextPath,UsePreviousValue=true \

   ParameterKey=DBRemoveAbandonedTimeout,UsePreviousValue=true \

   ParameterKey=ClusterNodeVolumeSize,UsePreviousValue=true \

   ParameterKey=DBPoolMinSize,UsePreviousValue=true \

   ParameterKey=DBTimeBetweenEvictionRunsMillis,UsePreviousValue=true \

   ParameterKey=PrivateSubnet1CIDR,UsePreviousValue=true \

   ParameterKey=DBEngineVersion,UsePreviousValue=true \

   ParameterKey=ExportPrefix,UsePreviousValue=true \

   ParameterKey=DBPoolMaxSize,UsePreviousValue=true \

   ParameterKey=DeploymentAutomationRepository,UsePreviousValue=true \

   ParameterKey=TomcatProtocol,UsePreviousValue=true

for iid in $(aws ec2 describe-instance-status --output yaml | grep InstanceId | tr -d ' ' | awk -F: '{ print $2 }')do  echo --------------------------------------------------------------------------------------------  str=aws:cloudformation:logical-id  aws ec2 describe-instances --instance-ids ${iid} --output table | grep "${str}" | sed 's/|//g' | tr -d ' ' | eval sed 's/${str}//'  echo ----------------  aws ec2 describe-instances --instance-ids ${iid} --output table | grep PrivateIpAddress | head -1 | sed 's/|//g' | tr -d ' ' | sed 's/ss/ss /'  aws ec2 describe-instances --instance-ids ${iid} --output table | grep PublicIp | head -1 | sed 's/|//g' | tr -d ' ' | sed 's/ss/ss /'done && echo --------------------------------------------------------------------------------------------

Remove old nodes from Jira Cluster

NOTE: This should happen automatically from Jira 8.10