Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
pyodide
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boxiang Sun
pyodide
Commits
cf55eb32
Commit
cf55eb32
authored
Oct 15, 2018
by
Roman Yurchak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Optimize the pyodide-env docker image
parent
ccd852c2
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
22 additions
and
5 deletions
+22
-5
.circleci/config.yml
.circleci/config.yml
+1
-1
Dockerfile
Dockerfile
+21
-4
No files found.
.circleci/config.yml
View file @
cf55eb32
...
...
@@ -3,7 +3,7 @@ version: 2
defaults
:
&defaults
working_directory
:
~/repo
docker
:
-
image
:
iodide/pyodide-env:0.2
.0
-
image
:
rthz/pyodide-env:0.3
.0
jobs
:
build
:
...
...
Dockerfile
View file @
cf55eb32
FROM
circleci/python:3.7.0-stretch
-browsers
FROM
circleci/python:3.7.0-stretch
# We need at least g++-8, but stretch comes with g++-6
# Set up the Debian testing repo, and then install g++ from there...
RUN
sudo
bash
-c
"echo
\"
deb http://ftp.us.debian.org/debian testing main contrib non-free
\"
>> /etc/apt/sources.list"
\
&&
sudo
apt-get update
\
&&
sudo
apt-get
install
node-less cmake build-essential clang-format-6.0 uglifyjs chromium ccache libncurses6
\
# for extracting firefox and running chrome, respectively
&& sudo apt-get install -y bzip2 libgconf-2-4 \
&& sudo apt-get install -t testing g++-8 \
&& sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-6 60 --slave /usr/bin/g++ g++ /usr/bin/g++-6 \
&& sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 80 --slave /usr/bin/g++ g++ /usr/bin/g++-8 \
...
...
@@ -14,7 +16,8 @@ RUN sudo bash -c "echo \"deb http://ftp.us.debian.org/debian testing main contri
&& sudo ln -s /usr/bin/clang-format-6.0 /usr/bin/clang-format \
&& sudo bash -c "echo 'application/wasm wasm' >> /etc/mime.types"
RUN
sudo
pip
install
pytest pytest-xdist pytest-instafail selenium PyYAML flake8
RUN
sudo
pip
install
pytest pytest-xdist pytest-instafail selenium PyYAML flake8
\
&&
sudo rm
-rf
/root/.cache/pip
# Get recent version of Firefox and geckodriver
RUN
sudo
wget
--quiet
-O
firefox.tar.bz2 https://download.mozilla.org/
\?
product
\=
firefox-latest-ssl
\&
os
\=
linux64
\&
lang
\=
en-US
\
...
...
@@ -22,11 +25,25 @@ RUN sudo wget --quiet -O firefox.tar.bz2 https://download.mozilla.org/\?product\
&&
sudo rm
-f
/usr/local/bin/firefox
\
&&
sudo ln
-s
$PWD
/firefox/firefox /usr/local/bin/firefox
\
&&
sudo
wget
--quiet
https://github.com/mozilla/geckodriver/releases/download/v0.21.0/geckodriver-v0.21.0-linux64.tar.gz
\
&&
sudo tar
zxf geckodriver-v0.21.0-linux64.tar.gz
-C
/usr/local/bin
&&
sudo tar
zxf geckodriver-v0.21.0-linux64.tar.gz
-C
/usr/local/bin
\
&&
sudo rm
-f
firefox.tar.bz2 geckodriver-v0.21.0-linux64.tar.gz
# Get recent version of chromedriver
RUN
sudo
wget
--quiet
https://chromedriver.storage.googleapis.com/2.41/chromedriver_linux64.zip
\
&&
sudo
unzip chromedriver_linux64.zip
\
&&
sudo mv
$PWD
/chromedriver /usr/local/bin
&&
sudo mv
$PWD
/chromedriver /usr/local/bin
\
&&
sudo rm
-f
chromedriver_linux64.zip
# start xvfb automatically to avoid needing to express in circle.yml
ENV
DISPLAY :99
RUN
printf
'#!/bin/sh\nXvfb :99 -screen 0 1280x1024x24 &\nexec "$@"\n'
>
/tmp/entrypoint
\
&&
chmod
+x /tmp/entrypoint
\
&&
sudo mv
/tmp/entrypoint /docker-entrypoint.sh
# ensure that the build agent doesn't override the entrypoint
LABEL
com.circleci.preserve-entrypoint=true
ENTRYPOINT
["/docker-entrypoint.sh"]
CMD
["/bin/sh"]
WORKDIR
/src
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment