Skip to content

Commit 405aae4

Browse files
committed
Only pip install if necessary
1 parent db9fca4 commit 405aae4

File tree

2 files changed

+12
-4
lines changed

2 files changed

+12
-4
lines changed

Diff for: performance-tests/scaling/ssh_to_hapi.sh

+4
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,6 @@
11
source ./variables.sh
2+
3+
set -e # Fail on errors.
4+
set -x # Show each command.
5+
26
gcloud compute ssh $VM_INSTANCE --zone $VM_ZONE --project $PROJECT_ID -- -o ProxyCommand='corp-ssh-helper %h %p'

Diff for: performance-tests/scaling/upload_download.sh

+8-4
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,14 @@ NOHUP_OUT=~/nohup-up.out
1616
cd $GITS_DIR/fhir-data-pipes
1717

1818
# Install Python virtual env.
19-
[[ -d $VENV ]] || python3 -m venv $VENV
20-
source $VENV/bin/activate
21-
# Install dependencies for uploader.
22-
pip install -r ./synthea-hiv/uploader/requirements.txt
19+
if [[ -d $VENV ]]; then
20+
source $VENV/bin/activate
21+
else
22+
python3 -m venv $VENV
23+
source $VENV/bin/activate
24+
# Install dependencies for uploader.
25+
pip install -r ./synthea-hiv/uploader/requirements.txt
26+
fi
2327

2428
nohup python "$DIR_WITH_THIS_SCRIPT/upload_download.py" >> $NOHUP_OUT 2>&1 &
2529
tail -F $NOHUP_OUT

0 commit comments

Comments
 (0)