diff --git a/activemq/lxcfile b/activemq/lxcfile index 8f6d29a..4ca7e6e 100644 --- a/activemq/lxcfile +++ b/activemq/lxcfile @@ -5,10 +5,8 @@ LAYER activemq/activemq SCRIPT # Download and install ActiveMQ - wget http://archive.apache.org/dist/activemq/5.15.5/apache-activemq-5.15.5-bin.tar.gz -O /tmp/activemq.tgz - tar xf /tmp/activemq.tgz -C /srv + wget http://archive.apache.org/dist/activemq/5.15.5/apache-activemq-5.15.5-bin.tar.gz -O - | tar xzf - -C /srv mv /srv/apache-activemq-5.15.5 /srv/activemq - rm -f /tmp/activemq.tgz # Create OS user addgroup -S -g 61616 activemq diff --git a/basic-runtimes/ruby.lxcfile b/basic-runtimes/ruby.lxcfile index 9cdb62e..27a9e6a 100644 --- a/basic-runtimes/ruby.lxcfile +++ b/basic-runtimes/ruby.lxcfile @@ -10,10 +10,8 @@ SCRIPT apk --no-cache add --virtual .deps build-base autoconf gdbm-dev libressl-dev linux-headers readline-dev zlib-dev # Download and unpack Ruby - wget http://cache.ruby-lang.org/pub/ruby/2.3/ruby-2.3.6.tar.xz -O ruby.tar.xz mkdir -p /usr/src/ruby - tar xJf ruby.tar.xz -C /usr/src/ruby --strip-components=1 - rm ruby.tar.xz + wget http://cache.ruby-lang.org/pub/ruby/2.3/ruby-2.3.6.tar.xz -O - | tar xJf - -C /usr/src/ruby --strip-components=1 cd /usr/src/ruby # Hackfix to suppress "Insecure world writable dir" warning diff --git a/basic-runtimes/tomcat.lxcfile b/basic-runtimes/tomcat.lxcfile index c89300a..cb0e944 100644 --- a/basic-runtimes/tomcat.lxcfile +++ b/basic-runtimes/tomcat.lxcfile @@ -5,8 +5,7 @@ LAYER shared/tomcat SCRIPT # Install Tomcat 8 - wget http://mirror.hosting90.cz/apache/tomcat/tomcat-8/v8.0.53/bin/apache-tomcat-8.0.53.tar.gz -O /tmp/apache-tomcat-8.tgz - tar xf /tmp/apache-tomcat-8.tgz -C /srv + wget http://mirror.hosting90.cz/apache/tomcat/tomcat-8/v8.0.53/bin/apache-tomcat-8.0.53.tar.gz | tar xzf - -C /srv mv /srv/apache-tomcat-8.0.53 /srv/tomcat # Make catalina.sh available globally @@ -14,7 +13,6 @@ SCRIPT # Cleanup rm -rf /srv/tomcat/webapps/ROOT /srv/tomcat/webapps/docs /srv/tomcat/webapps/examples /srv/tomcat/webapps/host-manager /srv/tomcat/webapps/manager - rm -f /tmp/apache-tomcat-8.tgz RUN COPY lxc-tomcat diff --git a/ckan/setup.sh b/ckan/setup.sh index b61f0c4..c9d4340 100755 --- a/ckan/setup.sh +++ b/ckan/setup.sh @@ -35,7 +35,7 @@ fi # Populate database lxc-execute -n ckan -- paster --plugin=ckan db init -c /etc/ckan/ckan.ini lxc-execute -n ckan -- paster --plugin=ckanext-spatial spatial initdb -c /etc/ckan/ckan.ini -lxc-execute -n ckan -- paster --plugin=ckan datastore set-permissions -c /etc/ckan/ckan.ini | lxc-execute -n postgres -- psql +lxc-execute -n ckan -- paster --plugin=ckan datastore set-permissions -c /etc/ckan/ckan.ini | lxc-attach -n postgres -- psql chown -R 8003:8003 /srv/ckan/data # Create admin account diff --git a/postgres/lxcfile b/postgres/lxcfile index 140555a..5ca04bd 100644 --- a/postgres/lxcfile +++ b/postgres/lxcfile @@ -21,4 +21,4 @@ RUN MOUNT /srv/postgres/data var/lib/postgresql USER 5432 5432 -CMD /init.lxc.static -- /usr/bin/postgres -D /var/lib/postgresql +CMD s6-setuidgid 5432:5432 /usr/bin/postgres -D /var/lib/postgresql diff --git a/redis/lxcfile b/redis/lxcfile index a1669b2..f2a2b26 100644 --- a/redis/lxcfile +++ b/redis/lxcfile @@ -15,4 +15,4 @@ MOUNT /srv/redis/conf/redis.conf etc/redis.conf MOUNT /srv/redis/data var/lib/redis USER 6379 6379 -CMD redis-server /etc/redis.conf +CMD s6-setuidgid 6379:6379 /usr/bin/redis-server /etc/redis.conf diff --git a/solr/lxcfile b/solr/lxcfile index 2af6946..2bed268 100644 --- a/solr/lxcfile +++ b/solr/lxcfile @@ -8,11 +8,9 @@ SCRIPT apk --no-cache add bash lsof # Download and install Solr - wget http://archive.apache.org/dist/lucene/solr/6.5.1/solr-6.5.1.tgz -O /tmp/solr-6.5.1.tgz mkdir /opt - tar xzf /tmp/solr-6.5.1.tgz -C /opt/ + wget http://archive.apache.org/dist/lucene/solr/6.5.1/solr-6.5.1.tgz -O - | tar xzf - -C /opt/ mv /opt/solr-6.5.1 /opt/solr - rm -f /tmp/solr-6.5.1.tgz # Create OS user addgroup -S -g 8983 solr @@ -29,4 +27,4 @@ RUN MOUNT /srv/solr/data var/lib/solr USER 8983 8983 -CMD solr start -f +CMD s6-setuidgid 5432:5432 /usr/bin/solr start -f