Skip to content

Commit

Permalink
Make GitPod works (kedro-org#2688)
Browse files Browse the repository at this point in the history
* update base image

Signed-off-by: Nok <[email protected]>

* update gitpod image and apt-get

Signed-off-by: Nok <[email protected]>

* update docker

Signed-off-by: Nok <[email protected]>
---------

Signed-off-by: Nok <[email protected]>
Signed-off-by: debugger24 <[email protected]>
  • Loading branch information
noklam authored and debugger24 committed Jun 28, 2023
1 parent cded6a2 commit a2ee7a1
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 22 deletions.
13 changes: 13 additions & 0 deletions .gitpod.Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
FROM gitpod/workspace-full:2023-05-08-21-16-55

# Some datasets work on 3.8 only
RUN pyenv install 3.8.15\
&& pyenv global 3.8.15

# VideoDataSet
RUN sudo apt-get update && sudo apt-get install -y --no-install-recommends libgl1
RUN sudo apt-get install make
RUN npm install -g @mermaid-js/mermaid-cli
# https://stackoverflow.com/questions/69564238/puppeteer-error-failed-to-launch-the-browser-process
# https://github.com/puppeteer/puppeteer/blob/main/docs/troubleshooting.md#chrome-doesnt-launch-on-linux
RUN sudo apt-get install -y --no-install-recommends libatk-bridge2.0-0 libcups2 ca-certificates fonts-liberation libasound2 libatk-bridge2.0-0 libatk1.0-0 libc6 libcairo2 libcups2 libdbus-1-3 libexpat1 libfontconfig1 libgbm1 libgcc1 libglib2.0-0 libgtk-3-0 libnspr4 libnss3 libpango-1.0-0 libpangocairo-1.0-0 libstdc++6 libx11-6 libx11-xcb1 libxcb1 libxcomposite1 libxcursor1 libxdamage1 libxext6 libxfixes3 libxi6 libxrandr2 libxrender1 libxss1 libxtst6 lsb-release wget xdg-utils
30 changes: 8 additions & 22 deletions .gitpod.yml
Original file line number Diff line number Diff line change
@@ -1,32 +1,18 @@
image: gitpod/workspace-full:legacy-dazzle-v1

image:
file: .gitpod.Dockerfile
tasks:
# We want packages installed during the pre-build init steps to go to /workspace
# rather than ~ so that they are persisted. Gitpod sets PIP_USER=yes to ensure this,
# but pre-commit requires PIP_USER=no. Hence we set PIP_USER=no and use
# pip install --user to install to /workspace.
- name: kedro
before: |
echo PIP_USER=no >> ~/.bashrc && export PIP_USER=no

init: |
make sign-off
pip install -r test_requirements.txt --user
gp sync-done kedro
command: |
pre-commit install --install-hooks
clear
# Generate a test Kedro project at /workspace/project using the local Kedro version.
- name: test-project
init: |
gp sync-await kedro
export PIP_USER=no
pip install -e /workspace/kedro
cd /workspace
pip install -e /workspace/kedro --no-deps
source ~/.bashrc
yes project | kedro new -s pandas-iris --checkout main
pip install -r /workspace/kedro/test_requirements.txt
cd /workspace/kedro
pre-commit install --install-hooks
command: |
pip install -e /workspace/kedro --no-deps
cd /workspace/project
clear
kedro info
Expand Down

0 comments on commit a2ee7a1

Please sign in to comment.