summaryrefslogtreecommitdiffstats
path: root/src/main/docker/include/etc
diff options
context:
space:
mode:
authorseanfos <sean.osullivan@est.tech>2021-07-06 16:51:00 +0100
committerseanfos <sean.osullivan@est.tech>2021-07-13 14:33:43 +0100
commit0468850d65e0f66082de4045bf656f51635e2a18 (patch)
tree61fe904ed376533571132e19a57eb6a29dff0d92 /src/main/docker/include/etc
parentccf424cf4b449fbd4e8d5447255e785036a63011 (diff)
[DMAAP-ZK] Zookeeper Upgrade6.1.0
Signed-off-by: seanfos <sean.osullivan@est.tech> Change-Id: I7079f201a0e474d1c59f0a23c09895ec345704ab Issue-ID: DMAAP-209
Diffstat (limited to 'src/main/docker/include/etc')
-rw-r--r--src/main/docker/include/etc/confluent/docker/configure33
-rw-r--r--src/main/docker/include/etc/confluent/docker/log4j.properties.template2
-rw-r--r--src/main/docker/include/etc/confluent/docker/run2
-rw-r--r--src/main/docker/include/etc/confluent/docker/tools-log4j.properties.template1
-rw-r--r--src/main/docker/include/etc/confluent/docker/zookeeper.properties.template51
5 files changed, 49 insertions, 40 deletions
diff --git a/src/main/docker/include/etc/confluent/docker/configure b/src/main/docker/include/etc/confluent/docker/configure
index 74e1c11..742207d 100644
--- a/src/main/docker/include/etc/confluent/docker/configure
+++ b/src/main/docker/include/etc/confluent/docker/configure
@@ -44,36 +44,3 @@ fi
dub template "/etc/confluent/docker/${COMPONENT}.properties.template" "/etc/kafka/${COMPONENT}.properties"
dub template "/etc/confluent/docker/log4j.properties.template" "/etc/kafka/log4j.properties"
dub template "/etc/confluent/docker/tools-log4j.properties.template" "/etc/kafka/tools-log4j.properties"
-
-
-ZK_REPLICAS=${ZOOKEEPER_REPLICAS:-1}
-HOST=$(hostname -s)
-DOMAIN=$(hostname -d)
-ZK_SERVER_PORT=${ZOOKEEPER_SERVER_PORT:-2888}
-ZK_ELECTION_PORT=${ZOOKEEPER_ELECTION_PORT:-3888}
-
-function print_servers() {
- if [[ $HOST =~ (.*)-([0-9]+)$ ]]; then
- NAME=${BASH_REMATCH[1]}
- for (( i=1; i<=$ZK_REPLICAS; i++ ))
- do
- echo "server.$i=$NAME-$((i-1)).$DOMAIN:$ZK_SERVER_PORT:$ZK_ELECTION_PORT"
- done
-
- fi
-}
-
-
-if [ $ZK_REPLICAS -gt 1 ]; then
-print_servers >> /etc/kafka/${COMPONENT}.properties
-fi
-
-if [ -d /var/lib/zookeeper/data/version-2 ]; then
- echo "API Keys already loaded";
- else
- cp -var /tmp/zookeeper/gerrit/oom-topics/data-zookeeper/* /var/lib/zookeeper/data/;
- rm -rf /tmp/zookeeper/gerrit;
- echo "Copying API Keys completed.";
- fi
-
-
diff --git a/src/main/docker/include/etc/confluent/docker/log4j.properties.template b/src/main/docker/include/etc/confluent/docker/log4j.properties.template
index 972bab3..9487292 100644
--- a/src/main/docker/include/etc/confluent/docker/log4j.properties.template
+++ b/src/main/docker/include/etc/confluent/docker/log4j.properties.template
@@ -7,7 +7,7 @@ log4j.appender.stdout.layout.ConversionPattern=[%d] %p %m (%c)%n
{% if env['ZOOKEEPER_LOG4J_LOGGERS'] %}
{% set loggers = parse_log4j_loggers(env['ZOOKEEPER_LOG4J_LOGGERS']) %}
-{% for logger,loglevel in loggers.iteritems() %}
+{% for logger,loglevel in loggers.items() %}
log4j.logger.{{logger}}={{loglevel}}, stdout
{% endfor %}
{% endif %}
diff --git a/src/main/docker/include/etc/confluent/docker/run b/src/main/docker/include/etc/confluent/docker/run
index 7d311e8..ee104fa 100644
--- a/src/main/docker/include/etc/confluent/docker/run
+++ b/src/main/docker/include/etc/confluent/docker/run
@@ -17,7 +17,7 @@
. /etc/confluent/docker/bash-config
echo "===> ENV Variables ..."
-show_env
+env
echo "===> User"
id
diff --git a/src/main/docker/include/etc/confluent/docker/tools-log4j.properties.template b/src/main/docker/include/etc/confluent/docker/tools-log4j.properties.template
index b8ad39c..d27685c 100644
--- a/src/main/docker/include/etc/confluent/docker/tools-log4j.properties.template
+++ b/src/main/docker/include/etc/confluent/docker/tools-log4j.properties.template
@@ -1,4 +1,3 @@
-
log4j.rootLogger={{ env["ZOOKEEPER_TOOLS_LOG4J_LOGLEVEL"] | default('WARN') }}, stderr
log4j.appender.stderr=org.apache.log4j.ConsoleAppender
diff --git a/src/main/docker/include/etc/confluent/docker/zookeeper.properties.template b/src/main/docker/include/etc/confluent/docker/zookeeper.properties.template
index e87e6b6..e46a3c9 100644
--- a/src/main/docker/include/etc/confluent/docker/zookeeper.properties.template
+++ b/src/main/docker/include/etc/confluent/docker/zookeeper.properties.template
@@ -1,10 +1,10 @@
-clientPort={{ env['ZOOKEEPER_CLIENT_PORT'] }}
dataDir=/var/lib/zookeeper/data
-dataLogDir=/var/lib/zookeeper/data
+dataLogDir=/var/lib/zookeeper/log
{# optional properties #}
{% set other_props = {
+ 'ZOOKEEPER_CLIENT_PORT' : 'clientPort',
'ZOOKEEPER_TICK_TIME': 'tickTime',
'ZOOKEEPER_GLOBAL_OUTSTANDING_LIMIT' : 'globalOutstandingLimit',
'ZOOKEEPER_PRE_ALLOC_SIZE': 'preAllocSize',
@@ -26,10 +26,53 @@ dataLogDir=/var/lib/zookeeper/data
'ZOOKEEPER_FORCE_SYNC': 'forceSync',
'ZOOKEEPER_JUTE_MAX_BUFFER': 'jute.maxbuffer',
'ZOOKEEPER_SKIP_ACL': 'skipACL',
- 'ZOOKEEPER_QUORUM_LISTEN_ON_ALL_IPS': 'quorumListenOnAllIPs'
+ 'ZOOKEEPER_QUORUM_LISTEN_ON_ALL_IPS': 'quorumListenOnAllIPs',
+ 'ZOOKEEPER_CLIENT_CNXN_SOCKET' : 'clientCnxnSocket',
+ 'ZOOKEEPER_SECURE_CLIENT_PORT' : 'secureClientPort',
+ 'ZOOKEEPER_SERVER_CNXN_SOCKET' : 'serverCnxnSocket',
+ 'ZOOKEEPER_X509_AUTHENTICATION_PROVIDER_SUPER_USER' : 'X509AuthenticationProvider.superUser',
+ 'ZOOKEEPER_SSL_AUTH_PROVIDER' : 'ssl.authProvider',
+ 'ZOOKEEPER_SSL_CLIENT_AUTH' : 'ssl.clientAuth',
+ 'ZOOKEEPER_SSL_KEYSTORE_LOCATION' : 'ssl.keyStore.location',
+ 'ZOOKEEPER_SSL_KEYSTORE_PASSWORD' : 'ssl.keyStore.password',
+ 'ZOOKEEPER_SSL_KEYSTORE_TYPE' : 'ssl.keyStore.type',
+ 'ZOOKEEPER_SSL_TRUSTSTORE_LOCATION' : 'ssl.trustStore.location',
+ 'ZOOKEEPER_SSL_TRUSTSTORE_PASSWORD' : 'ssl.trustStore.password',
+ 'ZOOKEEPER_SSL_TRUSTSTORE_TYPE' : 'ssl.trustStore.type',
+ 'ZOOKEEPER_SSL_ENABLED_PROTOCOLS' : 'ssl.enabledProtocols',
+ 'ZOOKEEPER_SSL_CONTEXT_SUPPLIER_CLASS' : 'ssl.context.supplier.class',
+ 'ZOOKEEPER_SSL_CIPHER_SUITES' : 'ssl.ciphersuites',
+ 'ZOOKEEPER_SSL_HOSTNAME_VERIFICATION' : 'ssl.hostnameVerification',
+ 'ZOOKEEPER_SSL_CRL' : 'ssl.crl',
+ 'ZOOKEEPER_SSL_OCPS' : 'ssl.ocsp',
+ 'ZOOKEEPER_SSL_HANDSHAKE_DETECTION_TIMEOUT_MILLIS' : 'ssl.handshakeDetectionTimeoutMillis',
+ 'ZOOKEEPER_SSL_QUORUM' : 'sslQuorum',
+ 'ZOOKEEPER_SSL_QUORUM_CLIENT_AUTH' : 'ssl.quorum.clientAuth',
+ 'ZOOKEEPER_SSL_QUORUM_KEYSTORE_LOCATION' : 'ssl.quorum.keyStore.location',
+ 'ZOOKEEPER_SSL_QUORUM_KEYSTORE_PASSWORD' : 'ssl.quorum.keyStore.password',
+ 'ZOOKEEPER_SSL_QUORUM_KEYSTORE_TYPE' : 'ssl.quorum.keyStore.type',
+ 'ZOOKEEPER_SSL_QUORUM_TRUSTSTORE_LOCATION' : 'ssl.quorum.trustStore.location',
+ 'ZOOKEEPER_SSL_QUORUM_TRUSTSTORE_PASSWORD' : 'ssl.quorum.trustStore.password',
+ 'ZOOKEEPER_SSL_QUORUM_TRUSTSTORE_TYPE' : 'ssl.quorum.trustStore.type',
+ 'ZOOKEEPER_SSL_QUORUM_ENABLED_PROTOCOLS' : 'ssl.quorum.enabledProtocols',
+ 'ZOOKEEPER_SSL_QUORUM_CIPHER_SUITES' : 'ssl.quorum.ciphersuites',
+ 'ZOOKEEPER_SSL_QUORUM_CONTEXT_SUPPLIER_CLASS' : 'ssl.quorum.context.supplier.class',
+ 'ZOOKEEPER_SSL_QUORUM_HOSTNAME_VERIFICATION' : 'ssl.quorum.hostnameVerification',
+ 'ZOOKEEPER_SSL_QUORUM_CRL' : 'ssl.quorum.crl',
+ 'ZOOKEEPER_SSL_QUORUM_OCPS' : 'ssl.quorum.ocsp',
+ 'ZOOKEEPER_SSL_QUORUM_HANDSHAKE_DETECTION_TIMEOUT_MILLIS' : 'ssl.quorum.handshakeDetectionTimeoutMillis',
+ 'ZOOKEEPER_SERVER_CNXN_FACTORY' : 'serverCnxnFactory',
+ 'ZOOKEEPER_AUTH_PROVIDER_X509' : 'authProvider.x509',
+ 'ZOOKEEPER_AUTH_PROVIDER_SASL' : 'authProvider.sasl',
+ 'ZOOKEEPER_CLIENT_PORT_UNIFICATION' : 'client.portUnification',
+ 'ZOOKEEPER_ADMIN_ENABLE_SERVER' : 'admin.enableServer',
+ 'ZOOKEEPER_ADMIN_SERVER_ADDRESS' : 'admin.serverAddress',
+ 'ZOOKEEPER_ADMIN_SERVER_PORT' : 'admin.serverPort',
+ 'ZOOKEEPER_ADMIN_IDLE_TIMEOUT' : 'admin.idleTimeout',
+ 'ZOOKEEPER_ADMIN_COMMAND_URL' : 'admin.commandURL'
} -%}
-{% for k, property in other_props.iteritems() -%}
+{% for k, property in other_props.items() -%}
{% if env.get(k) != None -%}
{{property}}={{env[k]}}
{% endif -%}