Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -235,11 +235,15 @@ jobs:
-f docker-compose.ranger-kafka.yml \
-f docker-compose.ranger-hive.yml \
-f docker-compose.ranger-knox.yml \
-f docker-compose.ranger-ozone.yml up -d
-f docker-compose.ranger-ozone.yml up -d --wait

- name: Debug Logs in OM Container
if: ${{ always() }}
run: |
docker logs -f ozone-om || true

- name: Check status of containers and remove them
run: |
sleep 60
containers=(ranger ranger-zk ranger-solr ranger-postgres ranger-hadoop ranger-hbase ranger-kafka ranger-hive ranger-knox ozone-om ozone-scm ozone-datanode);
flag=true;
for container in "${containers[@]}"; do
Expand Down
4 changes: 2 additions & 2 deletions dev-support/ranger-docker/docker-compose.ranger-hadoop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ services:
ranger:
condition: service_started
healthcheck:
test: ["CMD-SHELL", "/home/ranger/scripts/ranger-hadoop-healthcheck.sh"]
interval: 20s
test: [ "CMD-SHELL", "su hdfs -c \"/opt/hadoop/bin/hdfs dfsadmin -report | grep -q 'Live datanodes'\"" ]
interval: 30s
timeout: 10s
retries: 40
start_period: 40s
Expand Down
6 changes: 6 additions & 0 deletions dev-support/ranger-docker/docker-compose.ranger-hbase.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,12 @@ services:
condition: service_healthy
ranger-zk:
condition: service_started
healthcheck:
test: [ "CMD", "wget", "-q", "--spider", "http://localhost:16030/rs-status" ]
interval: 30s
timeout: 10s
retries: 30
start_period: 40s
environment:
- HBASE_VERSION
- HBASE_PLUGIN_VERSION
Expand Down
6 changes: 6 additions & 0 deletions dev-support/ranger-docker/docker-compose.ranger-hive.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,12 @@ services:
condition: service_started
ranger-hadoop:
condition: service_healthy
healthcheck:
test: [ "CMD-SHELL", "su hdfs -c \"/opt/hadoop/bin/hdfs dfsadmin -report | grep -q 'Live datanodes'\"" ]
interval: 30s
timeout: 10s
retries: 30
start_period: 40s
environment:
- HIVE_HADOOP_VERSION
- HIVE_VERSION
Expand Down
15 changes: 12 additions & 3 deletions dev-support/ranger-docker/docker-compose.ranger-kafka.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,19 @@ services:
condition: service_started
ranger-zk:
condition: service_started
healthcheck:
test: [ "CMD-SHELL", "echo 'ping' | kafka-console-producer.sh --broker-list localhost:9092 --topic health-check-topic && kafka-console-consumer.sh --bootstrap-server localhost:9092 --topic health-check-topic --from-beginning --max-messages 1 | grep 'ping'" ]
interval: 60s
timeout: 20s
retries: 5
start_period: 60s
environment:
- KAFKA_VERSION
- KAFKA_PLUGIN_VERSION
- KERBEROS_ENABLED
KAFKA_LISTENERS: PLAINTEXT://0.0.0.0:9092
KAFKA_ADVERTISED_LISTENERS: PLAINTEXT://ranger-kafka:9092,PLAINTEXT_HOST://localhost:9092
KAFKA_LISTENER_SECURITY_PROTOCOL_MAP: PLAINTEXT:PLAINTEXT,PLAINTEXT_HOST:PLAINTEXT
KAFKA_VERSION: ${KAFKA_VERSION}
KAFKA_PLUGIN_VERSION: ${KAFKA_PLUGIN_VERSION}
KERBEROS_ENABLED: ${KERBEROS_ENABLED}

networks:
ranger:
Expand Down
6 changes: 6 additions & 0 deletions dev-support/ranger-docker/docker-compose.ranger-kms.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,12 @@ services:
depends_on:
ranger:
condition: service_started
healthcheck:
test: [ "CMD-SHELL", "grep 'Ranger KMS Started' /var/log/ranger/kms/ranger-kms*.log" ]
interval: 40s
timeout: 5s
retries: 10
start_period: 40s
environment:
- KMS_VERSION
- RANGER_DB_TYPE
Expand Down
6 changes: 6 additions & 0 deletions dev-support/ranger-docker/docker-compose.ranger-knox.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,12 @@ services:
condition: service_started
ranger-zk:
condition: service_started
healthcheck:
test: [ "CMD-SHELL", "curl -k -i -u admin:admin-password 'https://localhost:8443/gateway/sandbox/webhdfs/v1/?op=LISTSTATUS'" ]
interval: 60s
timeout: 10s
retries: 10
start_period: 10s
environment:
- KNOX_VERSION
- KNOX_PLUGIN_VERSION
Expand Down
6 changes: 6 additions & 0 deletions dev-support/ranger-docker/docker-compose.ranger-ozone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,12 @@ services:
condition: service_started
ranger-solr:
condition: service_started
healthcheck:
test: [ "CMD-SHELL", "su om -c \"/opt/hadoop/bin/ozone fs -ls ofs://om/\"" ]
interval: 40s
timeout: 10s
retries: 5
start_period: 30s
environment:
ENSURE_OM_INITIALIZED: /data/metadata/om/current/VERSION
OZONE_OPTS: -Dcom.sun.net.ssl.checkRevocation=false
Expand Down
6 changes: 6 additions & 0 deletions dev-support/ranger-docker/docker-compose.ranger-tagsync.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,12 @@ services:
depends_on:
ranger:
condition: service_started
healthcheck:
test: [ "CMD-SHELL", "grep 'Initializing TAG source and sink' /var/log/ranger/tagsync/tagsync*log*" ]
interval: 30s
timeout: 3s
retries: 10
start_period: 40s
environment:
- TAGSYNC_VERSION
- DEBUG_TAGSYNC=${DEBUG_TAGSYNC:-false}
Expand Down
6 changes: 6 additions & 0 deletions dev-support/ranger-docker/docker-compose.ranger-usersync.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,12 @@ services:
depends_on:
ranger:
condition: service_started
healthcheck:
test: [ "CMD-SHELL", "grep 'uploaded to ranger admin' /var/log/ranger/usersync/usersync*.log*" ]
interval: 30s
timeout: 3s
retries: 10
start_period: 40s
environment:
- USERSYNC_VERSION
- ENABLE_FILE_SYNC_SOURCE
Expand Down
20 changes: 20 additions & 0 deletions dev-support/ranger-docker/docker-compose.ranger.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,12 @@ services:
condition: service_healthy
ranger-solr:
condition: service_started
healthcheck:
test: [ "CMD-SHELL", "curl -i -u admin:rangerR0cks! 'http://localhost:6080'" ]
interval: 60s
timeout: 10s
retries: 3
start_period: 40s
environment:
- RANGER_VERSION
- RANGER_DB_TYPE
Expand Down Expand Up @@ -82,6 +88,14 @@ services:
- ranger
ports:
- "2181:2181"
healthcheck:
test: [ "CMD-SHELL", "echo ruok | nc localhost 2181 | grep imok" ]
interval: 30s
timeout: 10s
retries: 5
start_period: 20s
environment:
ZOO_4LW_COMMANDS_WHITELIST: "mntr,conf,ruok"
environment:
- KERBEROS_ENABLED

Expand All @@ -106,6 +120,12 @@ services:
condition: service_started
ranger-zk:
condition: service_started
healthcheck:
test: [ "CMD-SHELL", "curl -f http://localhost:8983/solr/ranger_audits/admin/ping" ]
interval: 30s
timeout: 10s
retries: 5
start_period: 20s
environment:
- KERBEROS_ENABLED
- KRB5_CONFIG=/etc/krb5.conf
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@

cd "${OZONE_HOME}"/ranger-ozone-plugin || exit

rm -f "${OZONE_HOME}"/.setupDone
if [[ ! -f "${OZONE_HOME}"/.setupDone ]];
then
if [ ! -d conf ]; then
Expand Down
Loading