Browse Source
Make executable files to be able to run by non root and non thingsboa… (#2698 )
* Make executable files to be able to run by non root and non thingsboard user (to be in sync with OpenShift policies)
* Added default yes to agreement
pull/2700/head
VoBa
6 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with
18 additions and
6 deletions
msa/js-executor/docker/Dockerfile
msa/tb-node/docker/Dockerfile
msa/transport/coap/docker/Dockerfile
msa/transport/http/docker/Dockerfile
msa/transport/mqtt/docker/Dockerfile
msa/web-ui/docker/Dockerfile
@ -21,10 +21,12 @@ COPY start-js-executor.sh ${pkg.name}.deb /tmp/
RUN chmod a+x /tmp/*.sh \
&& mv /tmp/start-js-executor.sh /usr/bin
RUN dpkg -i /tmp/${ pkg .name } .deb
RUN yes | dpkg -i /tmp/${ pkg .name } .deb
RUN update-rc.d ${ pkg .name } disable
RUN chmod 555 ${ pkg .installFolder } /bin/${ pkg .name }
USER ${pkg.user}
CMD [ "start-js-executor.sh" ]
@ -21,12 +21,14 @@ COPY start-tb-node.sh ${pkg.name}.deb /tmp/
RUN chmod a+x /tmp/*.sh \
&& mv /tmp/start-tb-node.sh /usr/bin
RUN dpkg -i /tmp/${ pkg .name } .deb
RUN yes | dpkg -i /tmp/${ pkg .name } .deb
RUN systemctl --no-reload disable --now ${ pkg .name } .service > /dev/null 2>& 1 || :
RUN chown -R ${ pkg .user } :${ pkg .user } /tmp
RUN chmod 555 ${ pkg .installFolder } /bin/${ pkg .name } .jar
USER ${pkg.user}
CMD [ "start-tb-node.sh" ]
@ -21,10 +21,12 @@ COPY start-tb-coap-transport.sh ${pkg.name}.deb /tmp/
RUN chmod a+x /tmp/*.sh \
&& mv /tmp/start-tb-coap-transport.sh /usr/bin
RUN dpkg -i /tmp/${ pkg .name } .deb
RUN yes | dpkg -i /tmp/${ pkg .name } .deb
RUN update-rc.d ${ pkg .name } disable
RUN chmod 555 ${ pkg .installFolder } /bin/${ pkg .name } .jar
USER ${pkg.user}
CMD [ "start-tb-coap-transport.sh" ]
@ -21,10 +21,12 @@ COPY start-tb-http-transport.sh ${pkg.name}.deb /tmp/
RUN chmod a+x /tmp/*.sh \
&& mv /tmp/start-tb-http-transport.sh /usr/bin
RUN dpkg -i /tmp/${ pkg .name } .deb
RUN yes | dpkg -i /tmp/${ pkg .name } .deb
RUN update-rc.d ${ pkg .name } disable
RUN chmod 555 ${ pkg .installFolder } /bin/${ pkg .name } .jar
USER ${pkg.user}
CMD [ "start-tb-http-transport.sh" ]
@ -21,10 +21,12 @@ COPY start-tb-mqtt-transport.sh ${pkg.name}.deb /tmp/
RUN chmod a+x /tmp/*.sh \
&& mv /tmp/start-tb-mqtt-transport.sh /usr/bin
RUN dpkg -i /tmp/${ pkg .name } .deb
RUN yes | dpkg -i /tmp/${ pkg .name } .deb
RUN update-rc.d ${ pkg .name } disable
RUN chmod 555 ${ pkg .installFolder } /bin/${ pkg .name } .jar
USER ${pkg.user}
CMD [ "start-tb-mqtt-transport.sh" ]
@ -21,10 +21,12 @@ COPY start-web-ui.sh ${pkg.name}.deb /tmp/
RUN chmod a+x /tmp/*.sh \
&& mv /tmp/start-web-ui.sh /usr/bin
RUN dpkg -i /tmp/${ pkg .name } .deb
RUN yes | dpkg -i /tmp/${ pkg .name } .deb
RUN update-rc.d ${ pkg .name } disable
RUN chmod 555 ${ pkg .installFolder } /bin/${ pkg .name }
USER ${pkg.user}
CMD [ "start-web-ui.sh" ]