Skip to content

Commit

Permalink
pre-init Atlas for instant startup from image
Browse files Browse the repository at this point in the history
  • Loading branch information
sburn committed Jul 25, 2020
1 parent 1fafc9c commit c91b9eb
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,15 @@ RUN cd /opt/apache-atlas-${VERSION}/bin \
&& patch -b -f < atlas_config.py.patch \
&& sed -i 's/#export JAVA_HOME=/export JAVA_HOME=\/usr\/lib\/jvm\/java-8-openjdk-amd64/g' /opt/apache-atlas-${VERSION}/conf/atlas-env.sh

VOLUME ["/opt/apache-atlas-1.1.0/conf", "/opt/apache-atlas-1.1.0/logs"]
VOLUME ["/opt/apache-atlas-${VERSION}/conf", "/opt/apache-atlas-${VERSION}/logs"]

RUN cd /opt/apache-atlas-${VERSION}/bin \
&& ./atlas_start.py -setup || true
RUN cd /opt/apache-atlas-${VERSION} \
&& ./bin/atlas_start.py -setup || true

RUN cd /opt/apache-atlas-${VERSION} \
&& ./bin/atlas_start.py & \
touch /opt/apache-atlas-${VERSION}/logs/application.log \
&& tail -f /opt/apache-atlas-${VERSION}/logs/application.log | sed '/AuditFilter initialization started (AuditFilter:57)/ q' \
&& sleep 10 \
&& /opt/apache-atlas-${VERSION}/bin/atlas_stop.py

0 comments on commit c91b9eb

Please sign in to comment.