Skip to content

Commit

Permalink
changed instance type for qlik server (#1495)
Browse files Browse the repository at this point in the history
  • Loading branch information
LBH-wgreeff authored Nov 8, 2023
1 parent c07e148 commit 52e4353
Showing 1 changed file with 21 additions and 21 deletions.
42 changes: 21 additions & 21 deletions terraform/modules/qlik-sense-server/15-aws-ec2-prod.tf
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
locals {
backup_ami_id_prod = "ami-0a9bac68a32217ec9"
ec2_tags_prod = {
BackupPolicy = title(var.environment)
Name = "${var.identifier_prefix}-qlik-sense-restore"
}
ec2_tags_prod_restore = {
BackupPolicy = title(var.environment)
Name = "${var.identifier_prefix}-qlik-sense-restore-2"
}
backup_ami_id_prod = "ami-0a9bac68a32217ec9"
ec2_tags_prod = {
BackupPolicy = title(var.environment)
Name = "${var.identifier_prefix}-qlik-sense-restore"
}
ec2_tags_prod_restore = {
BackupPolicy = title(var.environment)
Name = "${var.identifier_prefix}-qlik-sense-restore-2"
}
}

#manually added/managed value
Expand All @@ -22,11 +22,11 @@ data "aws_secretsmanager_secret_version" "subnet_value_for_qlik_sense_prod_insta
}

resource "aws_instance" "qlik_sense_prod_instance" {
count = var.is_production_environment ? 1 : 0
ami = local.backup_ami_id_prod
instance_type = "c5.4xlarge"
subnet_id = data.aws_secretsmanager_secret_version.subnet_value_for_qlik_sense_prod_instance[0].secret_string
vpc_security_group_ids = [aws_security_group.qlik_sense.id]
count = var.is_production_environment ? 1 : 0
ami = local.backup_ami_id_prod
instance_type = "c6i.4xlarge"
subnet_id = data.aws_secretsmanager_secret_version.subnet_value_for_qlik_sense_prod_instance[0].secret_string
vpc_security_group_ids = [aws_security_group.qlik_sense.id]

private_dns_name_options {
enable_resource_name_dns_a_record = true
Expand All @@ -39,18 +39,18 @@ resource "aws_instance" "qlik_sense_prod_instance" {
associate_public_ip_address = false

root_block_device {
encrypted = true
delete_on_termination = false
kms_key_id = aws_kms_key.key.arn
tags = merge(var.tags, local.ec2_tags_prod)
volume_size = 1000
volume_type = "gp3"
encrypted = true
delete_on_termination = false
kms_key_id = aws_kms_key.key.arn
tags = merge(var.tags, local.ec2_tags_prod)
volume_size = 1000
volume_type = "gp3"
}

lifecycle {
ignore_changes = [ami, subnet_id]
}

metadata_options {
http_tokens = "required"
http_endpoint = "enabled"
Expand Down

0 comments on commit 52e4353

Please sign in to comment.