Skip to content

Commit 2b8ff85

Browse files
sbalousekDjelibeybi
authored andcommitted
Oracle GoldenGate
- Address review comments Signed-off-by: Stephen Balousek <[email protected]>
1 parent 84f8b14 commit 2b8ff85

File tree

11 files changed

+17
-42
lines changed

11 files changed

+17
-42
lines changed

OracleGoldenGate/23/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
## Copyright (c) 2021, Oracle and/or its affiliates.
1+
## Copyright (c) 2024, Oracle and/or its affiliates.
22
ARG BASE_IMAGE=oraclelinux:8
33
# hadolint ignore=DL3006
44
FROM ${BASE_IMAGE}

OracleGoldenGate/23/bin/create-certificate.sh

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,11 @@
11
#!/bin/bash
2-
## Copyright (c) 2021, Oracle and/or its affiliates.
2+
## Copyright (c) 2024, Oracle and/or its affiliates.
33
set -e
44

55
: "${NGINX_CRT:?}"
66
: "${NGINX_KEY:?}"
77

88
##
9-
## c r e a t e _ c e r t i f i c a t e
109
## Create a self-signed certificate/key pair
1110
##
1211
function create_certificate() {

OracleGoldenGate/23/bin/deployment-init.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
1-
#!/bin/python3
1+
#!/usr/bin/env python3
22
## Copyright (c) 2021, 2024, Oracle and/or its affiliates.
33

44
##
5-
## d e p l o y m e n t - i n i t . p y
65
## Initialize OGG Deployment
76
##
87

OracleGoldenGate/23/bin/deployment-main.sh

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,12 @@
11
#!/bin/bash
2-
## Copyright (c) 2022, Oracle and/or its affiliates.
2+
## Copyright (c) 2024, Oracle and/or its affiliates.
33
set -e
44

55
##
6-
## d e p l o y m e n t - m a i n . s h
76
## Execute OGG Deployment
87
##
98

109
##
11-
## a b o r t
1210
## Terminate with an error message
1311
##
1412
function abort() {
@@ -36,7 +34,6 @@ NGINX_KEY="$(awk '$1 == "ssl_certificate_key" { gsub(/;/, ""); print $NF; exit }
3634
export OGG_DEPLOYMENT OGG_ADMIN NGINX_CRT NGINX_KEY
3735

3836
##
39-
## g e n e r a t e P a s s w o r d
4037
## If not already specified, generate a random password with:
4138
## - at least one uppercase character
4239
## - at least one lowercase character
@@ -61,7 +58,6 @@ function generatePassword {
6158
}
6259

6360
##
64-
## l o c a t e _ j a v a
6561
## Locate the Java installation and set JAVA_HOME
6662
##
6763
function locate_java() {
@@ -76,7 +72,6 @@ function locate_java() {
7672
}
7773

7874
##
79-
## l o c a t e _ l i b _ j v m
8075
## Locate the shared library libjvm.so and set LD_LIBRARY_PATH
8176
##
8277
function locate_lib_jvm() {
@@ -94,7 +89,6 @@ function locate_lib_jvm() {
9489
}
9590

9691
##
97-
## r u n _ a s _ o g g
9892
## Return a string used for running a process as the 'ogg' user
9993
##
10094
function run_as_ogg() {
@@ -106,7 +100,6 @@ function run_as_ogg() {
106100
}
107101

108102
##
109-
## s e t u p _ d e p l o y m e n t _ d i r e c t o r i e s
110103
## Create and set permissions for directories for the deployment
111104
##
112105
function setup_deployment_directories() {
@@ -125,7 +118,6 @@ function setup_deployment_directories() {
125118
}
126119

127120
##
128-
## r u n _ u s e r _ s c r i p t s
129121
## Run custom scripts in the container before and after GoldenGate starts
130122
##
131123
function run_user_scripts {
@@ -145,7 +137,6 @@ function run_user_scripts {
145137
}
146138

147139
##
148-
## s t a r t _ o g g
149140
## Initialize and start the OGG installation
150141
##
151142
function start_ogg() {
@@ -155,8 +146,7 @@ function start_ogg() {
155146
}
156147

157148
##
158-
## s t a r t _ n g i n x
159-
## Start the NGinx reverse proxy daemon
149+
## Start the reverse proxy daemon
160150
##
161151
function start_nginx() {
162152
[[ ! -f "${NGINX_CRT}" || ! -f "${NGINX_KEY}" ]] && {

OracleGoldenGate/23/bin/healthcheck

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
#!/bin/bash
2-
## Copyright (c) 2021, Oracle and/or its affiliates.
2+
## Copyright (c) 2024, Oracle and/or its affiliates.
33

44
##
5-
## h e a l t h c h e c k
65
## Check the health of all services in the deployment.
76
##
87

OracleGoldenGate/23/bin/replace-variables.sh

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
#!/bin/bash
2-
## Copyright (c) 2021, Oracle and/or its affiliates.
2+
## Copyright (c) 2024, Oracle and/or its affiliates.
33
set -e
44

55
##
6-
## r e p l a c e - v a r i a b l e s . s h
76
## Replace environment variables with their values in one or more text files
87
##
98

OracleGoldenGate/23/install-deployment.sh

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/bin/bash
2-
## Copyright (c) 2022, Oracle and/or its affiliates.
2+
## Copyright (c) 2024, Oracle and/or its affiliates.
33
set -e
44

55
: "${INSTALLER:?}"
@@ -9,12 +9,10 @@ ORA_HOME="/u01/app"
99
INSTALLER="/tmp/installer.zip"
1010

1111
##
12-
## i n s t a l l - d e p l o y m e n t . s h
1312
## Install the deployment from a "ShipHome" ZIP file
1413
##
1514

1615
##
17-
## a b o r t
1816
## Terminate with an error message
1917
##
2018
function abort() {
@@ -23,7 +21,6 @@ function abort() {
2321
}
2422

2523
##
26-
## r u n _ a s _ o g g
2724
## Return a string used for running a process as the 'ogg' user
2825
##
2926
function run_as_ogg() {
@@ -35,7 +32,6 @@ function run_as_ogg() {
3532
}
3633

3734
##
38-
## o g g _ i n s t a l l e r _ s e t u p
3935
## Unpack the OGG installation software
4036
##
4137
function ogg_installer_setup() {
@@ -46,7 +42,6 @@ function ogg_installer_setup() {
4642
}
4743

4844
##
49-
## o g g _ i n s t a l l _ o p t i o n
5045
## Get the INSTALL_OPTION.
5146
##
5247
function ogg_install_option() {
@@ -62,7 +57,6 @@ function ogg_install_option() {
6257
}
6358

6459
##
65-
## o g g _ i n s t a l l
6660
## Perform an OGG installation
6761
##
6862
function ogg_install() {
Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,12 @@
11
#!/bin/bash
2-
## Copyright (c) 2021, Oracle and/or its affiliates.
2+
## Copyright (c) 2024, Oracle and/or its affiliates.
33
set -e
44

55
##
6-
## i n s t a l l - p r e r e q u i s i t e s . s h
76
## Installation of prerequisite software
87
##
98

10-
packages=(java-1.8.0-openjdk jq libaio libnsl python39-requests python39-psutil tar unzip xz)
11-
12-
packages+=(unixODBC) ## Required only for Microsoft SQL Server
13-
packages+=(compat-openssl10 mariadb-common) ## Required only for MySQL
14-
packages+=(libpq) ## Required only for PostgreSQL
9+
packages=(java-17-openjdk jq libaio libnsl nginx perl python39 python39-requests python39-psutil tar unzip xz)
1510

1611
function success() {
1712
echo "Packages installed after ${sequence} attempts"
@@ -23,7 +18,7 @@ function success() {
2318
## Attempt the module and package installation up to three times
2419
## in case there are network issues that cause failures.
2520
for sequence in $(seq 3); do
26-
dnf -y module install nginx python39 && \
27-
dnf -y install "${packages[@]}" && success "${sequence}"
21+
dnf -y module enable nginx:1.22 python39 && \
22+
dnf -y install "${packages[@]}" && success "${sequence}"
2823
done
2924
exit 1

OracleGoldenGate/23/nginx/nginx.conf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
## Copyright (c) 2021, Oracle and/or its affiliates.
1+
## Copyright (c) 2024, Oracle and/or its affiliates.
22

33
##
44
## nginx.conf
5-
## Configuration file for Nginx Reverse Proxy
5+
## Configuration file for reverse proxy
66
##
77

88
user nginx;

OracleGoldenGate/23/nginx/ogg-headers.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
## Copyright (c) 2020, Oracle and/or its affiliates.
1+
## Copyright (c) 2024, Oracle and/or its affiliates.
22

33
##
44
## ogg-headers.conf

OracleGoldenGate/23/nginx/ogg.conf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
## Copyright (c) 2021, Oracle and/or its affiliates.
1+
## Copyright (c) 2024, Oracle and/or its affiliates.
22

33
##
44
## ogg.conf
5-
## Nginx configuration file for OGG Deployment
5+
## Configuration file for OGG Deployment
66
##
77

88
##

0 commit comments

Comments
 (0)