Commit 35665ff7 authored by Luca Cinquini's avatar Luca Cinquini
Browse files

Merge branch 'dev_1.4_sg' into dev_1.4_lc

parents a98f1544 d9ea96f5
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -107,6 +107,7 @@ COPY scripts/ /usr/local/bin/
COPY conf/supervisord.cog.conf /etc/supervisor/conf.d/supervisord.cog.conf
# wait for Postgred connection to be ready
COPY scripts/wait_for_postgres.sh /usr/local/bin/wait_for_postgres.sh
COPY scripts/process_esgf_config_archive.sh /usr/local/bin/process_esgf_config_archive.sh
ENTRYPOINT ["/usr/local/bin/docker-entrypoint.sh"]
# will override these CMD options at run time
CMD ["localhost", "false", "true"]
+4 −0
Original line number Diff line number Diff line
@@ -17,6 +17,10 @@ echo "RUNSERVER=$RUNSERVER"
echo "untar grid certificates"
mkdir /etc/grid-security
tar --same-owner -pxaf /root/archives/grid_security_certs.tar.xz -C /etc/grid-security
chmod -R 664 /etc/grid-security/certificates

# deploy esgf config files
/usr/local/bin/process_esgf_config_archive.sh

# wait for Postgred connection to be ready
/usr/local/bin/wait_for_postgres.sh
+18 −0
Original line number Diff line number Diff line
#!/bin/bash

echo "untar esgf config files"
mkdir -p /esg
tar --same-owner -pxaf /root/archives/esgf_config.tar.xz -C /esg

echo "set permissions"
chmod 644 /esg/config/*
#chown root:tomcat /esg/config/.esg*
chmod 640 /esg/config/.esg*

#chown -R tomcat:tomcat /esg/config/tomcat
chmod 755 /esg/config/tomcat
chmod 600 /esg/config/tomcat/*

chmod 755 /esg/config/esgcet
chmod 644 /esg/config/esgcet/*
chmod 640 /esg/config/esgcet/esg.ini
 No newline at end of file
+3 −2
Original line number Diff line number Diff line
@@ -213,5 +213,6 @@ RUN mkdir -p $DASHBOARD_HOME/logs

#===========================================

# startup configuration inherited from esgf-tomcat image
CMD ["supervisord", "--nodaemon", "-c", "/etc/supervisord.conf"]
COPY scripts/docker-entrypoint.sh /usr/local/bin/docker-entrypoint.sh
COPY scripts/process_esgf_config_archive.sh /usr/local/bin/process_esgf_config_archive.sh
ENTRYPOINT /usr/local/bin/docker-entrypoint.sh
+5 −11
Original line number Diff line number Diff line
#!/bin/bash
# Default script to start Tomcat inside a container
# Script to start ESGF data node

# start Tomcat in the background (so it can be restarted without stopping the container)
# note: additional startup parameters are read from bin/setenv.sh
$CATALINA_HOME/bin/catalina.sh start
# deploy esgf config files
/usr/local/bin/process_esgf_config_archive.sh

# keep container running by printing log to standard output
logfile=/usr/local/tomcat/logs/catalina.out
while ! [ -f $logfile ];
do
    sleep 1
done
tail -f $logfile
# startup configuration inherited from esgf-tomcat image
supervisord --nodaemon -c /etc/supervisord.conf
 No newline at end of file
Loading