Dockerfile 1.0 KB

123456789101112131415161718192021222324252627
  1. ######################
  2. ## Dockerfile to build container images consisting of Node.js and nginx environment
  3. # Based on Ubuntu
  4. #####
  5. # Set the base image to Ubuntu
  6. FROM ubuntu
  7. # File Author / Maintainer
  8. # MAINTAINER name Chunteng Xiao
  9. RUN apt-get clean
  10. RUN apt-get update
  11. RUN apt-get install -y software-properties-common
  12. # RUN add-apt-repository ppa:certbot/certbot
  13. RUN apt-get update
  14. RUN apt-get -f install -y nodejs nginx npm curl unzip
  15. RUN curl --insecure -o ./sonarscanner.zip -L https://sonarsource.bintray.com/Distribution/sonar-scanner-cli/sonar-scanner-cli-3.2.0.1227-linux.zip
  16. RUN unzip sonarscanner.zip
  17. RUN rm sonarscanner.zip
  18. ENV SONAR_RUNNER_HOME=/sonar-scanner-3.2.0.1227-linux
  19. ENV PATH $PATH:/sonar-scanner-3.2.0.1227-linux/bin
  20. COPY sonar-runner.properties ./sonar-scanner-3.2.0.1227-linux/conf/sonar-scanner.properties
  21. RUN npm install cnpm -g --registry=https://registry.npm.taobao.org
  22. RUN cnpm install gitbook-cli -g
  23. ADD default /etc/nginx/sites-available
  24. # RUN certbot --nginx
  25. # RUN certbot renew --dry-run
  26. EXPOSE 80