File tree Expand file tree Collapse file tree 1 file changed +15
-0
lines changed
Expand file tree Collapse file tree 1 file changed +15
-0
lines changed Original file line number Diff line number Diff line change 1515 echo " permit-opa directory already exists. Skipping clone operation."
1616fi
1717
18+ # Check if datasync directory already exists
19+ if [ ! -d " ../datasync" ]; then
20+ # Clone the permit-opa repository into the parent directory if it doesn't exist
21+ git clone git@github.com:permitio/datasync.git ../datasync
22+ else
23+ echo " datasync directory already exists. Skipping clone operation."
24+ fi
25+
1826# Conditionally execute the custom OPA tarball creation section based on the value of PDP_VANILLA
1927if [ " $PDP_VANILLA " != " true" ]; then
2028 # Custom OPA tarball creation section
@@ -24,6 +32,13 @@ if [ "$PDP_VANILLA" != "true" ]; then
2432 cd " ../permit-opa"
2533 find * -name ' *go*' -print0 | xargs -0 tar -czf " $build_root " /custom/custom_opa.tar.gz --exclude ' .*'
2634 cd " $build_root "
35+ # Datasync tarball creation section
36+ rm -rf datasync
37+ mkdir datasync
38+ build_root=" $PWD "
39+ cd " ../datasync"
40+ find * -name ' *go*' -print0 | xargs -0 tar -czf " $build_root " /datasync/datasync.tar.gz --exclude ' .*'
41+ cd " $build_root "
2742else
2843 echo " Skipping custom OPA tarball creation for pdp-vanilla environment."
2944fi
You can’t perform that action at this time.
0 commit comments