Skip to content

Commit 673ffc3

Browse files
committed
OracleGoldenGate 23 - Adding support for python startup scripts
1 parent 4211b90 commit 673ffc3

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

OracleGoldenGate/23/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ Version 23.4 ...
160160

161161
### Running Scripts Before Setup and on Startup
162162

163-
The container images can be configured to run scripts before setup and on startup. Currently, `.sh` extensions are supported. For setup scripts just mount the volume `/u01/ogg/scripts/setup` or extend the image to include scripts in this directory. For startup scripts just mount the volume `/u01/ogg/scripts/startup` or extend the image to include scripts in this directory. Both of those locations
163+
The container images can be configured to run scripts before setup and on startup. Currently, `.sh` and `.py` extensions are supported. For setup scripts just mount the volume `/u01/ogg/scripts/setup` or extend the image to include scripts in this directory. For startup scripts just mount the volume `/u01/ogg/scripts/startup` or extend the image to include scripts in this directory. Both of those locations
164164
are static and the content is controlled by the volume mount.
165165

166166
The example below mounts the local directory `${PWD}/myScripts` to `/u01/ogg/scripts` which is then searched for custom startup scripts:

OracleGoldenGate/23/bin/deployment-main.sh

+5-1
Original file line numberDiff line numberDiff line change
@@ -125,10 +125,14 @@ function run_user_scripts {
125125
while read -r script; do
126126
case "${script}" in
127127
*.sh)
128-
echo "Running script '${script}'"
128+
echo "Running shell script '${script}'"
129129
# shellcheck disable=SC1090
130130
source "${script}"
131131
;;
132+
*.py)
133+
echo "Running python script '${script}'"
134+
python3 "${script}"
135+
;;
132136
*)
133137
echo "Ignoring '${script}'"
134138
;;

0 commit comments

Comments
 (0)