Dockerfile 1.5 KB

1234567891011121314151617181920212223242526272829303132333435
  1. FROM ubuntu:jammy
  2. # Install Git
  3. RUN apt-get update && \
  4. apt-get install sudo -y && \
  5. apt-get install git -y
  6. # Install Docker
  7. RUN apt-get install ca-certificates curl gnupg -y && \
  8. curl -fsSL https://download.docker.com/linux/ubuntu/gpg | gpg --dearmor -o /etc/apt/keyrings/docker.gpg && \
  9. echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu $(. /etc/os-release && echo "$VERSION_CODENAME") stable" | tee /etc/apt/sources.list.d/docker.list > /dev/null && \
  10. apt-get update && \
  11. apt-get install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin -y
  12. # Install Nodejs v20 npm
  13. RUN sudo apt-get update && \
  14. sudo apt-get install -y ca-certificates curl gnupg && \
  15. sudo mkdir -p /etc/apt/keyrings && \
  16. curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | sudo gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg
  17. RUN echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_20.x nodistro main" | sudo tee /etc/apt/sources.list.d/nodesource.list && \
  18. sudo apt-get update && \
  19. sudo apt-get install nodejs -y
  20. # Install gpt-crawler
  21. RUN cd /home && git clone https://github.com/builderio/gpt-crawler && cd gpt-crawler && \
  22. npm i && \
  23. npx playwright install && \
  24. npx playwright install-deps
  25. # Directory to mount in the docker container to get the output.json data
  26. RUN cd /home && mkdir data
  27. WORKDIR /home