You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

49 lines
1.2 KiB

  1. FROM ubuntu:latest
  2. RUN apt-get update -y
  3. RUN apt-get install git -y
  4. RUN apt-get install -y curl
  5. RUN apt-get install -y wget
  6. #install Nodejs
  7. RUN curl -sL https://deb.nodesource.com/setup_6.x | bash -
  8. RUN apt-get install -y nodejs
  9. RUN apt-get install -y build-essential
  10. #install MongoDB
  11. RUN \
  12. apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 0C49F3730359A14518585931BC711F9BA15703C6 && \
  13. echo "deb [ arch=amd64,arm64 ] http://repo.mongodb.org/apt/ubuntu xenial/mongodb-org/3.4 multiverse" | tee /etc/apt/sources.list.d/mongodb-org-3.4.list && \
  14. apt-get update && \
  15. apt-get install -y mongodb-org
  16. #install bower
  17. RUN npm install -g bower
  18. RUN npm install -g forever
  19. #donwload commonroutesServer
  20. RUN git clone https://github.com/arnaucode/commonroutesServer.git
  21. RUN cd commonroutesServer
  22. RUN npm install
  23. #run mongodb service
  24. CMD service mongod start
  25. CMD cd commonroutesServer && \
  26. forever start server.js
  27. #commands to use:
  28. #docker build -t containername .
  29. #docker run -ti containername /bin/bash
  30. #docker start -ti containername /bin/bash
  31. #docker ps -a
  32. #docker rm containernametodelete
  33. #docker images
  34. #docker rmi imagenametodelete
  35. # delete all containers
  36. #docker rm $(docker ps -a -q)
  37. # delete all images
  38. #docker rmi $(docker images -q)