Skip to content

Commit 2e43245

Browse files
Joachim92Djelibeybi
authored andcommitted
OracleGoldenGate 23 - Adding support for python startup scripts
1 parent a59ab9b commit 2e43245

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

OracleGoldenGate/23/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ Version 23.4 ...
163163

164164
### Running Scripts Before Setup and on Startup
165165

166-
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
166+
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
167167
are static and the content is controlled by the volume mount.
168168

169169
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

Lines changed: 5 additions & 1 deletion
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)