Procházet zdrojové kódy

HUE-9020 [core] Improve Hue and Hue Load Balancer docker image generation.

(cherry picked from commit d8a7b9a7ad6da1105c623b2f5d3bb613d6d2203c)
(cherry picked from commit 9a0bf40f156a4120faa9e41f1f03daeda04a2ab5)
Prakash Ranade před 6 roky
rodič
revize
0a2aff8bc1

+ 4 - 1
tools/container/build.sh

@@ -37,7 +37,10 @@ subst_var() {
     fi
     fi
   fi
   fi
 
 
-  envsubst < $file_name > $out_name
+  eval "cat <<EOF
+$(<$file_name)
+EOF
+" | tee $out_name 2> /dev/null
 }
 }
 
 
 docker_hue_build() {
 docker_hue_build() {

+ 1 - 1
tools/container/hue/Dockerfile

@@ -40,7 +40,7 @@ RUN mkdir -p ${HUE_CONF} && chown -R ${HUE_USER}:${HUE_USER} ${HUE_CONF}
 RUN echo "${HUE_USER} ALL=(root) NOPASSWD:ALL" > /etc/sudoers.d/${HUE_USER} && \
 RUN echo "${HUE_USER} ALL=(root) NOPASSWD:ALL" > /etc/sudoers.d/${HUE_USER} && \
     chmod 0440 /etc/sudoers.d/${HUE_USER}
     chmod 0440 /etc/sudoers.d/${HUE_USER}
 
 
-COPY --chown=${HUE_USER}:${HUE_USER} hueconf ${HUE_CONF_DIR}
+COPY --chown=${HUE_USER}:${HUE_USER} hueconf ${HUE_CONF}/conf
 
 
 RUN ln -s ${HUE_CONF}/conf/log.conf ${HUE_HOME}/desktop/conf/log.conf; \
 RUN ln -s ${HUE_CONF}/conf/log.conf ${HUE_HOME}/desktop/conf/log.conf; \
     ln -s ${HUE_CONF}/conf/log4j.properties ${HUE_HOME}/desktop/conf/log4j.properties
     ln -s ${HUE_CONF}/conf/log4j.properties ${HUE_HOME}/desktop/conf/log4j.properties

+ 2 - 0
tools/container/huelb/hue_httpd_template

@@ -33,6 +33,8 @@ LogLevel warn
   Require all granted
   Require all granted
 </Directory>
 </Directory>
 
 
+Alias /static ${HUE_HOME}/build/static
+
 Header add Set-Cookie "ROUTEID=.%{BALANCER_WORKER_ROUTE}e; path=/" env=BALANCER_ROUTE_CHANGED
 Header add Set-Cookie "ROUTEID=.%{BALANCER_WORKER_ROUTE}e; path=/" env=BALANCER_ROUTE_CHANGED
 ProxyPreserveHost Off
 ProxyPreserveHost Off
 ProxyPass /static !
 ProxyPass /static !