github.com/web-platform-tests/wpt.fyi@v0.0.0-20240530210107-70cf978996f1/Dockerfile (about) 1 # vim: set expandtab sw=4 2 FROM golang:1.20.14-bullseye 3 4 # Create a non-priviledged user to run browsers as (Firefox and Chrome do not 5 # like to run as root). 6 RUN chmod a+rx $HOME && useradd --uid 9999 --user-group --create-home browser 7 8 # Sort the package names! 9 # firefox-esr: provides deps for Firefox (we don't use ESR directly) 10 # openjdk-11-jdk: provides JDK/JRE to Selenium & gcloud SDK 11 # python-crcmod: native module to speed up CRC checksum in gsutil 12 RUN apt-get update -qqy && apt-get install -qqy --no-install-suggests \ 13 curl \ 14 firefox-esr \ 15 lsb-release \ 16 openjdk-11-jdk \ 17 python3.9 \ 18 python3-crcmod \ 19 sudo \ 20 tox \ 21 wget \ 22 xvfb && \ 23 rm /usr/bin/firefox 24 25 # The base golang image adds Go paths to PATH, which cannot be inherited in 26 # sudo by default because of the `secure_path` directive. Overwrite sudoers to 27 # discard the setting. 28 RUN echo "root ALL=(ALL:ALL) ALL" > /etc/sudoers 29 30 # Node LTS 31 RUN curl -sL https://deb.nodesource.com/setup_18.x | bash - && \ 32 apt-get install -qqy nodejs 33 34 # Google Cloud SDK 35 # Based on https://github.com/GoogleCloudPlatform/cloud-sdk-docker/blob/master/Dockerfile 36 RUN export CLOUD_SDK_REPO="cloud-sdk-$(lsb_release -c -s)" && \ 37 echo "deb https://packages.cloud.google.com/apt $CLOUD_SDK_REPO main" > /etc/apt/sources.list.d/google-cloud-sdk.list && \ 38 curl -s https://packages.cloud.google.com/apt/doc/apt-key.gpg | apt-key add - && \ 39 apt-get update -qqy && apt-get install -qqy \ 40 google-cloud-sdk \ 41 google-cloud-sdk-app-engine-python \ 42 google-cloud-sdk-app-engine-python-extras \ 43 google-cloud-sdk-app-engine-go \ 44 google-cloud-sdk-datastore-emulator && \ 45 gcloud config set core/disable_usage_reporting true && \ 46 gcloud config set component_manager/disable_update_check true && \ 47 gcloud --version