X-Git-Url: https://gerrit.akraino.org/r/gitweb?a=blobdiff_plain;ds=sidebyside;f=example-apps%2FROBO%2Fretail_app%2FDockerfile;h=cad2cf5bcb02aad40a30519181eacaf310348285;hb=8be0e289aa30f9832b916f14d8821c9c9fe3b62e;hp=c84560a78fb54da988b0b7aefe3b1ef79f9dd840;hpb=8f08e671bdc47a1a98a290fc9284d7bb2337283b;p=ealt-edge.git diff --git a/example-apps/ROBO/retail_app/Dockerfile b/example-apps/ROBO/retail_app/Dockerfile index c84560a..cad2cf5 100644 --- a/example-apps/ROBO/retail_app/Dockerfile +++ b/example-apps/ROBO/retail_app/Dockerfile @@ -16,17 +16,22 @@ # Prepare stage for multistage image build ## START OF STAGE0 ## -FROM python:3.6-slim-stretch - +# FROM python:3.6-slim-stretch +# FROM python:3.9 +# FROM python:3.9-slim-buster # # CREATE APP USER ## + +FROM python:2.7 + # Set umask RUN sed -i "s|umask 022|umask 027|g" /etc/profile # Create the home directory for the new app user. RUN mkdir -p /usr/app RUN mkdir -p /usr/app/bin -RUN mkdir -p /usr/app/detection -RUN mkdir -p /usr/app/resources +RUN mkdir -p /usr/app/inventry +RUN mkdir -p /usr/app/test/resources +RUN mkdir -p /usr/app/images_result # Set the home directory to our app user's home. ENV APP_HOME=/usr/app @@ -35,6 +40,7 @@ ENV GID=166 ENV USER_NAME=eguser ENV GROUP_NAME=eggroup ENV ENV="/etc/profile" +ENV PYTHONUNBUFFERED=0 # Create an app user so our program doesn't run as root. RUN apt-get -y update &&\ @@ -50,7 +56,6 @@ RUN apt-get install -y --fix-missing \ curl \ graphicsmagick \ libgraphicsmagick1-dev \ - libatlas-dev \ libavcodec-dev \ libavformat-dev \ libgtk2.0-dev \ @@ -58,10 +63,9 @@ RUN apt-get install -y --fix-missing \ liblapack-dev \ libswscale-dev \ pkg-config \ - python3-dev \ - python3-numpy \ software-properties-common \ zip \ + imagemagick \ && apt-get clean && rm -rf /tmp/* /var/tmp/* # Set the working directory. @@ -69,9 +73,11 @@ WORKDIR $APP_HOME # Copy the application & scripts COPY config.py requirements.txt run.py $APP_HOME/ -COPY detection $APP_HOME/monitoring/ -COPY resources $APP_HOME/resources/ -COPY configs/*.sh $APP_HOME/bin +COPY inventry $APP_HOME/inventry/ + +COPY test $APP_HOME/test/ +COPY test/resources $APP_HOME/test/resources/ +COPY configs/start.sh $APP_HOME/bin RUN chmod 750 $APP_HOME &&\ chmod -R 550 $APP_HOME/bin &&\ @@ -80,7 +86,7 @@ RUN chmod 750 $APP_HOME &&\ chown -R $USER_NAME:$GROUP_NAME $APP_HOME # Exposed port -EXPOSE 9997 +EXPOSE 9995 # Change to the app user. USER $USER_NAME