Skip to content

Commit ff676fa

Browse files
Set environment variable COCKROACH_ROACHPROD_INSECURE to false.
Epic: none Release note: None
1 parent be6c437 commit ff676fa

File tree

5 files changed

+23
-5
lines changed

5 files changed

+23
-5
lines changed

pkg/cmd/drtprod/configs/drt_pua_9.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ environment:
1313
WORKLOAD_CLUSTER: workload-pua-9
1414
WORKLOAD_NODES: 1
1515
STORE_COUNT: 2
16+
COCKROACH_ROACHPROD_INSECURE: false
1617

1718
TPCC_WAREHOUSES: 5000
1819
TPCC_ACTIVE_WAREHOUSES: 5000

pkg/cmd/drtprod/configs/drt_pua_mr.yaml

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ environment:
1212
CLUSTER_NODES: 15
1313
WORKLOAD_NODES: 3
1414
STORE_COUNT: 2
15+
COCKROACH_ROACHPROD_INSECURE: false
1516

1617
# variables used by tpcc_run_multiregion.sh
1718
NUM_REGIONS: 3
@@ -34,6 +35,7 @@ environment:
3435

3536
dependent_file_locations:
3637
- artifacts/roachprod
38+
- artifacts/drtprod
3739
- artifacts/roachtest
3840
- pkg/cmd/drtprod/scripts/setup_dmsetup_disk_staller
3941
- pkg/cmd/drtprod/scripts/setup_datadog_cluster
@@ -60,7 +62,7 @@ targets:
6062
gce-local-ssd-count: $STORE_COUNT
6163
os-volume-size: 100
6264
username: drt
63-
lifetime: 8760h
65+
lifetime: 15h
6466
on_rollback:
6567
- command: destroy
6668
args:
@@ -150,7 +152,7 @@ targets:
150152
gce-machine-type: n2d-standard-4
151153
os-volume-size: 100
152154
username: workload
153-
lifetime: 8760h
155+
lifetime: 15h
154156
on_rollback:
155157
- command: destroy
156158
args:
@@ -171,6 +173,11 @@ targets:
171173
- $WORKLOAD_CLUSTER
172174
- artifacts/roachprod
173175
- roachprod
176+
- command: put
177+
args:
178+
- $WORKLOAD_CLUSTER
179+
- artifacts/drtprod
180+
- drtprod
174181
- command: put
175182
args:
176183
- $WORKLOAD_CLUSTER:1
@@ -368,3 +375,4 @@ targets:
368375
- $CLUSTER:11-15
369376
flags:
370377
restart: true
378+
wait_after: 3300

pkg/cmd/drtprod/scripts/generate_tpcc_run.sh

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,11 @@ if [ -z "${PARTITION_TYPE}" ]; then
6565
fi
6666

6767
export ROACHPROD_DISABLED_PROVIDERS=IBM
68+
# Clusters created via drtprod default to secure mode. This script is intended to
69+
# run on secure clusters. In the past we have run into compatibility issues
70+
# between roachprod and drtprod. To make this script resilient to incompatibility
71+
# and allow use with insecure clusters, we can configure this env variable.
72+
export COCKROACH_ROACHPROD_INSECURE="${COCKROACH_ROACHPROD_INSECURE:-false}"
6873

6974
get_partitions_in_range() {
7075
local start=$(($1 - 1))
@@ -122,6 +127,7 @@ for ((NODE=0; NODE<WORKLOAD_NODES; NODE++)); do
122127
123128
export ROACHPROD_DISABLED_PROVIDERS=IBM
124129
export ROACHPROD_GCE_DEFAULT_PROJECT=$ROACHPROD_GCE_DEFAULT_PROJECT
130+
export COCKROACH_ROACHPROD_INSECURE="${COCKROACH_ROACHPROD_INSECURE:-false}"
125131
./drtprod sync
126132
127133
PGURLS=\$(./drtprod load-balancer pgurl $CLUSTER | sed s/\'//g)

pkg/cmd/drtprod/scripts/tpcc_init.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ if [ -z "${WORKLOAD_CLUSTER}" ]; then
3737
fi
3838

3939
export ROACHPROD_DISABLED_PROVIDERS=IBM
40+
export COCKROACH_ROACHPROD_INSECURE="${COCKROACH_ROACHPROD_INSECURE:-false}"
4041

4142
absolute_path=$(drtprod run "${WORKLOAD_CLUSTER}":1 -- "realpath ./cockroach")
4243
pwd=$(drtprod run "${WORKLOAD_CLUSTER}":1 -- "dirname ${absolute_path}")

pkg/cmd/drtprod/scripts/tpcc_run_multiregion.sh

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ for var in "${env_vars[@]}"; do
2929
done
3030

3131
export ROACHPROD_DISABLED_PROVIDERS=IBM
32+
export COCKROACH_ROACHPROD_INSECURE="${COCKROACH_ROACHPROD_INSECURE:-false}"
3233

3334
for NODE in $(seq 1 $NUM_REGIONS)
3435
do
@@ -49,11 +50,12 @@ do
4950
5051
export ROACHPROD_DISABLED_PROVIDERS=IBM
5152
export ROACHPROD_GCE_DEFAULT_PROJECT=$ROACHPROD_GCE_DEFAULT_PROJECT
52-
./roachprod sync
53-
PGURLS=\$(./roachprod load-balancer pgurl $CLUSTER | sed s/\'//g)
53+
export COCKROACH_ROACHPROD_INSECURE="${COCKROACH_ROACHPROD_INSECURE:-false}"
54+
./drtprod sync
55+
PGURLS=\$(./drtprod load-balancer pgurl $CLUSTER | sed s/\'//g)
5456
if [ -z "\$PGURLS" ]; then
5557
echo ">> No load-balancer configured; falling back to direct pgurl"
56-
PGURLS=\$(./roachprod pgurl $CLUSTER | sed s/\'//g)
58+
PGURLS=\$(./drtprod pgurl $CLUSTER | sed s/\'//g)
5759
fi
5860
read -r -a PGURLS_REGION <<< "\$PGURLS"
5961

0 commit comments

Comments
 (0)