Skip to content

Commit 560e042

Browse files
change: remove dev-only defaults
add: random minio secret
1 parent 50a09de commit 560e042

File tree

2 files changed

+47
-46
lines changed

2 files changed

+47
-46
lines changed

application.tf

Lines changed: 23 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1028,6 +1028,20 @@ module "intake_smoketests" {
10281028
helm_values = indent(10, trimspace(local.smoketests_values))
10291029
}
10301030

1031+
resource "random_password" "minio-password" {
1032+
length = 16
1033+
special = false
1034+
}
1035+
1036+
output "minio-username" {
1037+
value = "indico"
1038+
}
1039+
1040+
output "minio-password" {
1041+
sensitive = true
1042+
value = random_password.minio-password.result
1043+
}
1044+
10311045
locals {
10321046
insights_pre_reqs_values = [<<EOF
10331047
crunchy-postgres:
@@ -1117,14 +1131,10 @@ crunchy-postgres:
11171131
ingress:
11181132
useStaticCertificate: false
11191133
secretName: indico-ssl-static-cert
1120-
tls.crt: #base64 encoded value of certificate chain
1121-
tls.key: #base64 encoded value of certificate key
11221134
minio:
1123-
topology:
1124-
volumeSize: 128Gi
11251135
storage:
1126-
accessKey: <path:tools/argo/data/indico-dev/ins-dev/storage#access_key_id>
1127-
secretKey: <path:tools/argo/data/indico-dev/ins-dev/storage#secret_access_key>
1136+
accessKey: ${random_password.minio-username.result}
1137+
secretKey: ${random_password.minio-password.result}
11281138
backup:
11291139
enabled: ${var.include_miniobkp}
11301140
schedule: "0 4 * * 2" # This schedules the job to run at 4:00 AM every Tuesday
@@ -1139,20 +1149,22 @@ weaviate:
11391149
weaviate-backup:
11401150
enabled: true
11411151
backupStorageConfig:
1142-
accessKey: <path:tools/argo/data/indico-dev/ins-dev/storage#access_key_id>
1143-
secretKey: <path:tools/argo/data/indico-dev/ins-dev/storage#secret_access_key>
1152+
accessKey: ${random_password.minio-username.result}
1153+
secretKey: ${random_password.minio-password.result}
11441154
url: http://minio-tenant-hl.insights.svc.cluster.local:9000
11451155
weaviate:
11461156
env:
1147-
GOMEMLIMIT: "31GiB" # 1 less than the hard limit on the used nodes
1157+
# 1 less than the hard limit of the weaviate node group type
1158+
GOMEMLIMIT: "31GiB"
1159+
# TODO: switch this to a dedicated weaviate backup bucket
11481160
backups:
11491161
s3:
11501162
enabled: true
11511163
envconfig:
11521164
BACKUP_S3_ENDPOINT: minio-tenant-hl.insights.svc.cluster.local:9000
11531165
secrets:
1154-
AWS_ACCESS_KEY_ID: <path:tools/argo/data/indico-dev/ins-dev/storage#access_key_id>
1155-
AWS_SECRET_ACCESS_KEY: <path:tools/argo/data/indico-dev/ins-dev/storage#secret_access_key>
1166+
AWS_ACCESS_KEY_ID: ${random_password.minio-username.result}
1167+
AWS_SECRET_ACCESS_KEY: ${random_password.minio-password.result}
11561168
rabbitmq:
11571169
rabbitmq:
11581170
image:
@@ -1167,15 +1179,6 @@ global:
11671179
host: ${lower("${var.label}.${var.region}.${var.aws_account}.indico.io")}
11681180
features:
11691181
askMyDocument: true
1170-
insights-edge:
1171-
additionalAllowedOrigins:
1172-
- https://local.indico.io:1234
1173-
server:
1174-
services:
1175-
lagoon:
1176-
env:
1177-
FIELD_AUTOCONFIRM_CONFIDENCE: 0.8
1178-
FIELD_CONFIG_PATH: "fields_config.yaml"
11791182
ask-my-docs:
11801183
llmConfig:
11811184
llm: indico-azure-instance

azure/application.tf

Lines changed: 24 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -824,6 +824,20 @@ module "intake_smoketests" {
824824
helm_values = indent(10, trimspace(local.smoketests_values))
825825
}
826826

827+
resource "random_password" "minio-password" {
828+
length = 16
829+
special = false
830+
}
831+
832+
output "minio-username" {
833+
value = "indico"
834+
}
835+
836+
output "minio-password" {
837+
sensitive = true
838+
value = random_password.minio-password.result
839+
}
840+
827841
locals {
828842
insights_pre_reqs_values = [<<EOF
829843
crunchy-postgres:
@@ -910,37 +924,35 @@ crunchy-postgres:
910924
ingress:
911925
useStaticCertificate: false
912926
secretName: indico-ssl-static-cert
913-
tls.crt: #base64 encoded value of certificate chain
914-
tls.key: #base64 encoded value of certificate key
915927
minio:
916928
createStorageClass: false
917929
topology:
918-
volumeSize: 128Gi
919930
storageClassName: default
920931
storage:
921-
accessKey: <path:tools/argo/data/indico-dev/ins-dev/storage#access_key_id>
922-
secretKey: <path:tools/argo/data/indico-dev/ins-dev/storage#secret_access_key>
932+
accessKey: ${random_password.minio-username.result}
933+
secretKey: ${random_password.minio-password.result}
923934
weaviate:
924935
cronjob:
925936
services:
926937
weaviate-backup:
927938
enabled: true
928939
backupStorageConfig:
929-
accessKey: <path:tools/argo/data/indico-dev/ins-dev/storage#access_key_id>
930-
secretKey: <path:tools/argo/data/indico-dev/ins-dev/storage#secret_access_key>
940+
accessKey: ${random_password.minio-username.result}
941+
secretKey: ${random_password.minio-password.result}
931942
url: http://minio-tenant-hl.insights.svc.cluster.local:9000
932943
weaviate:
933944
env:
934-
GOMEMLIMIT: "31GiB" # 1 less than the hard limit on the used nodes
935-
# TODO: enable this when we have a backup bucket
945+
# 1 less than the hard limit of the weaviate node group type
946+
GOMEMLIMIT: "31GiB"
947+
# TODO: switch this to a dedicated weaviate backup bucket
936948
backups:
937949
s3:
938-
enabled: false
950+
enabled: true
939951
envconfig:
940952
BACKUP_S3_ENDPOINT: minio-tenant-hl.insights.svc.cluster.local:9000
941953
secrets:
942-
AWS_ACCESS_KEY_ID: <path:tools/argo/data/indico-dev/ins-dev/storage#access_key_id>
943-
AWS_SECRET_ACCESS_KEY: <path:tools/argo/data/indico-dev/ins-dev/storage#secret_access_key>
954+
AWS_ACCESS_KEY_ID: ${random_password.minio-username.result}
955+
AWS_SECRET_ACCESS_KEY: ${random_password.minio-password.result}
944956
EOF
945957
]
946958

@@ -949,20 +961,6 @@ global:
949961
host: ${var.label}.${var.region}.indico-dev.indico.io
950962
features:
951963
askMyDocument: true
952-
intake:
953-
host: dev-ci.us-east-2.indico-dev.indico.io
954-
apiToken: <path:tools/argo/data/indico-dev/ins-dev/intake#api_token>
955-
tokenSecret: <path:tools/argo/data/indico-dev/ins-dev/intake#noct_token_secret>
956-
cookieSecret: <path:tools/argo/data/indico-dev/ins-dev/intake#noct_cookie_secret>
957-
insights-edge:
958-
additionalAllowedOrigins:
959-
- https://local.indico.io:1234
960-
server:
961-
services:
962-
lagoon:
963-
env:
964-
FIELD_AUTOCONFIRM_CONFIDENCE: 0.8
965-
FIELD_CONFIG_PATH: "fields_config.yaml"
966964
ask-my-docs:
967965
llmConfig:
968966
llm: indico-azure-instance

0 commit comments

Comments
 (0)