添加opencv和springboot的容器环境

This commit is contained in:
KennyLee 2020-07-02 11:40:39 +08:00
parent 117f84280f
commit cb197abdc6
5 changed files with 29 additions and 3 deletions

8
opencv/springboot/Dockerfile Executable file
View File

@ -0,0 +1,8 @@
FROM registry.cn-hangzhou.aliyuncs.com/kennylee/opencv:openjdk-jdk8
MAINTAINER kennylee26 <kennylee26@gmail.com>
COPY entrypoint.sh /entrypoint.sh
RUN chmod +x /entrypoint.sh
ENTRYPOINT "/entrypoint.sh"

View File

@ -0,0 +1,18 @@
#! /bin/bash
BASE_PATH=/data/app/
ORI_APP_FILE=$(find ${BASE_PATH} -type f -name "*.jar" 2>/dev/null | head -1)
APP_FILE=${BASE_PATH}app.jar
if [[ ${#ORI_APP_FILE} -gt 0 ]]; then
echo "create symbolic link for $ORI_APP_FILE"
if [[ -e ${APP_FILE} ]]; then
#echo "$APP_FILE was existed, remove that."
rm -f ${APP_FILE}
fi
ln -s ${ORI_APP_FILE} ${APP_FILE}
fi
# if $APP_FILE not exist, let it throw error。
java ${JAVA_OPTS} -jar ${APP_FILE} "$@"

View File

@ -1,4 +1,4 @@
FROM registry.cn-hangzhou.aliyuncs.com/kennylee/opencv:openjdk-jdk8
FROM registry.cn-hangzhou.aliyuncs.com/kennylee/opencv:openjdk-jdk8
MAINTAINER kennylee26 <kennylee26@gmail.com>

View File

@ -1,4 +1,4 @@
version: '3'
version: '2'
services:
redis:

View File

@ -3,7 +3,7 @@ server {
server_name localhost;
ssl on;
ssl_certificate /etc/ssl/certs/localhost.crt;
ssl_certificate /etc/ssl/certs/localhost.pem;
ssl_certificate_key /etc/ssl/private/localhost.key;
#charset koi8-r;