Sign inSign up

cbergh/analytic_micro_service

By cbergh

•Updated about 11 years ago

Image
0

313

cbergh/analytic_micro_service repository overview

#@IgnoreInspection BashAddShebang ############################################################

⁠Dockerfile to build Python AnalyticMicroServer Application Containers

⁠Based on Ubuntu

############################################################

⁠Set the base image to Ubuntu

FROM ubuntu

⁠File Author / Maintainer

MAINTAINER DataKitchen

⁠Add the application resources URL

RUN echo "deb http://archive.ubuntu.com/ubuntu/⁠ $(lsb_release -sc) main universe" >> /etc/apt/sources.list

⁠Update the sources list

RUN sudo apt-get update

⁠Install basic applications

RUN sudo apt-get install -y tar git curl nano wget dialog net-tools build-essential emacs

⁠Install Python and Basic Python Tools

RUN sudo apt-get install -y python python-dev python-distribute python-pip

⁠Install AnalyticMicroService Python Tools

RUN sudo pip install flask flask-restful AnalyticMicroService

⁠make a directory for the server

RUN mkdir /AnalyticMicroService

#setup that diirectory RUN cp /usr/local/lib/python2.7/dist-packages/server/app/AMSapp.py /AnalyticMicroService/AMSapp.py RUN echo '{ "port-number": "14001" }' >> /AnalyticMicroService/AMSConfig.json

⁠Expose ports

EXPOSE 14001

⁠Set the default directory where CMD will execute

WORKDIR /AnalyticMicroService

⁠Set the default command to execute

CMD python AMSapp.py --config /AnalyticMicroService/AMSConfig.json

⁠build 'sudo docker build -t test_ams .'

⁠run this (if name test_ams) 'sudo docker run -name test_ams_instance -p 14001:14001 -i -t test_ams'

Tag summary

Content type

Image

Digest

sha256:3798b8884…

Size

-

Last updated

about 11 years ago

docker pull cbergh/analytic_micro_service:base_v1