Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Theia IDE browser.Dockerfile not working #345

Closed
dannaf opened this issue Mar 28, 2024 · 0 comments · Fixed by #346
Closed

Theia IDE browser.Dockerfile not working #345

dannaf opened this issue Mar 28, 2024 · 0 comments · Fixed by #346

Comments

@dannaf
Copy link
Contributor

dannaf commented Mar 28, 2024

Bug Description:

Building Theia IDE with the provided browser.Dockerfile does not currently work.

Steps to Reproduce:

  1. git clone https://github.com/eclipse-theia/theia-blueprint
  2. cd theia-blueprint
  3. docker build -t theia-ide -f browser.Dockerfile . (like instructed here)

Additional Information

(I only switched the docker tag to theia-blueprint because I already had an image named theia-ide on my machine that I did not want to mess up. I should have probably called it theia-ide2, but I didn't; remphasizing #339 while we're on that.)

dannaf@downstairs:~/theia-blueprint$ sudo docker build -t theia-blueprint -f browser.Dockerfile .
[+] Building 87.3s (11/17)                                                                                                                                            docker:default
 => [internal] load build definition from browser.Dockerfile                                                                                                                    0.4s
 => => transferring dockerfile: 2.66kB                                                                                                                                          0.0s
 => [internal] load metadata for docker.io/library/node:16-bullseye-slim                                                                                                        0.7s
 => [internal] load metadata for docker.io/library/node:16-bullseye                                                                                                             0.8s
 => [internal] load .dockerignore                                                                                                                                               0.2s
 => => transferring context: 2B                                                                                                                                                 0.0s
 => [build-stage 1/5] FROM docker.io/library/node:16-bullseye@sha256:cd59a61258b82b86c1ff0ead50c8a689f6c3483c5ed21036e11ee741add419eb                                           0.0s
 => [internal] load build context                                                                                                                                               0.2s
 => => transferring context: 13.60kB                                                                                                                                            0.0s
 => [production-stage 1/7] FROM docker.io/library/node:16-bullseye-slim@sha256:503446c15c6236291222f8192513c2eb56a02a8949cbadf4fe78cce19815c734                                 0.0s
 => CACHED [build-stage 2/5] RUN apt-get update && apt-get install -y libxkbfile-dev libsecret-1-dev                                                                            0.0s
 => CACHED [build-stage 3/5] WORKDIR /home/theia                                                                                                                                0.0s
 => CACHED [build-stage 4/5] COPY . .                                                                                                                                           0.0s
 => ERROR [build-stage 5/5] RUN yarn --pure-lockfile &&     yarn build:extensions &&     yarn download:plugins &&     yarn browser build &&     yarn --production &&     yarn  84.5s
------                                                                                                                                                                               
 > [build-stage 5/5] RUN yarn --pure-lockfile &&     yarn build:extensions &&     yarn download:plugins &&     yarn browser build &&     yarn --production &&     yarn autoclean --init &&     echo *.ts >> .yarnclean &&     echo *.ts.map >> .yarnclean &&     echo *.spec.* >> .yarnclean &&     yarn autoclean --force &&     yarn cache clean &&     rm -r .git applications/electron theia-extensions/launcher theia-extensions/updater node_modules:                                                                                                    
1.321 yarn install v1.22.19                                                                                                                                                          
1.582 [1/5] Validating package.json...                                                                                                                                               
1.597 [2/5] Resolving packages...
2.598 warning Resolution field "@yarnpkg/[email protected]" is incompatible with requested version "@yarnpkg/[email protected]"
2.978 warning Resolution field "[email protected]" is incompatible with requested version "msgpackr@^1.10.1"
3.841 [3/5] Fetching packages...
81.91 error [email protected]: The engine "node" is incompatible with this module. Expected version ">= 18.0.0". Got "16.20.2"
81.93 error Found incompatible module.
81.93 info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
------
browser.Dockerfile:15
--------------------
  14 |     # Use yarn autoclean to remove unnecessary files from package dependencies
  15 | >>> RUN yarn --pure-lockfile && \
  16 | >>>     yarn build:extensions && \
  17 | >>>     yarn download:plugins && \
  18 | >>>     yarn browser build && \
  19 | >>>     yarn --production && \
  20 | >>>     yarn autoclean --init && \
  21 | >>>     echo *.ts >> .yarnclean && \
  22 | >>>     echo *.ts.map >> .yarnclean && \
  23 | >>>     echo *.spec.* >> .yarnclean && \
  24 | >>>     yarn autoclean --force && \
  25 | >>>     yarn cache clean && \
  26 | >>>     rm -r .git applications/electron theia-extensions/launcher theia-extensions/updater node_modules
  27 |     
--------------------
ERROR: failed to solve: process "/bin/sh -c yarn --pure-lockfile &&     yarn build:extensions &&     yarn download:plugins &&     yarn browser build &&     yarn --production &&     yarn autoclean --init &&     echo *.ts >> .yarnclean &&     echo *.ts.map >> .yarnclean &&     echo *.spec.* >> .yarnclean &&     yarn autoclean --force &&     yarn cache clean &&     rm -r .git applications/electron theia-extensions/launcher theia-extensions/updater node_modules" did not complete successfully: exit code: 1

System Information

  • Operating System: Ubuntu 24.04
  • Theia Version: 1.47.100 (per here, yes?—or is it from here)
dannaf added a commit to dannaf/theia-blueprint that referenced this issue Mar 28, 2024
Resolves eclipse-theia#345

`node:16-bullseye` seems outdated and resulted in the bug documented in the above issue.  It is not currently supported on the official list of node docker images:
https://hub.docker.com/_/node

The issue at eclipse-theia#345 was resolved even by changing to `node:18-bullseye` only in the `build-stage`, but presumably it should be already upgraded also in the `production-stage`, so this commit/PR also updates the production stage based image.
jfaltermeier pushed a commit that referenced this issue Apr 2, 2024
Resolves #345

`node:16-bullseye` seems outdated and resulted in the bug documented in the above issue.  It is not currently supported on the official list of node docker images:
https://hub.docker.com/_/node

The issue at #345 was resolved even by changing to `node:18-bullseye` only in the `build-stage`, but presumably it should be already upgraded also in the `production-stage`, so this commit/PR also updates the production stage based image.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant