GithubHelp home page GithubHelp logo

Comments (9)

raethlein avatar raethlein commented on July 19, 2024

Hey @stamerf, thanks a lot for the appreciation :) We will update VS Code in the next version of ml-workspace.
In the meantime, you can execute the code in the bottom in your running workspace instance.
To do so, go to your workspace instance > New (top-right corner below "Open Tool") > Terminal
Paste the following lines and press enter (although this code should not break anything, think about backing up your data / code so that you can restart a fresh instance just in case):

# Stop the code server process
supervisorctl stop vscode

# Replace the version in our installer script
sed -i 's/VS_CODE_VERSION=3.8.0/VS_CODE_VERSION=3.9.1/g' /resources/tools/vs-code-server.sh

# Remove the executable link file
rm /usr/bin/code-server

# Remove the current code-server version
yarn global remove code-server

# Install the new version
/resources/tools/vs-code-server.sh

# Start the code server process again
supervisorctl start vscode

I have tested it with the newest workspace image mltooling/ml-workspace:0.12.1. Though I have not tested it in conjunction with ml-hub or older versions of ml-workspace.

I hope this helps! If you have more feedback, we would love to hear about it.

from ml-hub.

stamerf avatar stamerf commented on July 19, 2024

Thank you very much for the fast response, I appreciate it a lot. Unfortunately, the docker image used when following your quick install guide on the homepage for mlhub is using code-server Version: 1.38.1 @ downloadlink https://github.com/cdr/code-server/releases/download/2.1478-vsc1.38.1/code-server2.1478-vsc1.38.1-linux-x86_64.tar.gz . The update ist not as easy as you described it. I tried fixing it, but the new version is running quite differently. E.g. multiple flags are not valid anymore like --allow-http or --no-auth. Therefore I rolled back to the old version. Maybe the Image from docker hub is just too old? I don't know actually. If it would be the case, building the image myself would fix it I guess.

from ml-hub.

raethlein avatar raethlein commented on July 19, 2024

Ah yes, ML Hub uses by default a quite old workspace image. You can create a file locally called jupyterhub_user_config.py with the following content:

c.Spawner.image = "mltooling/ml-workspace:0.12.1"

and pass it to the docker run command via -v <path_to_your_jupyterhub_user_config.py>:/resources/jupyterhub_user_config.py, for example like this:

docker run \                    
    -p 8080 \
    -v /var/run/docker.sock:/var/run/docker.sock \
    -v jupyterhub_data:/data \
    -v $(pwd)/jupyterhub_user_config.py:/resources/jupyterhub_user_config.py \
    mltooling/ml-hub:latest
   
# Note: $(pwd) resolves to the current directory, e.g. /Users/ben/Documents -> /Users/ben/Documents/jupyterhub_user_config.py)

With this config, the default workspace image used by hub is mltooling/ml-workspace:0.12.1.
You have to remove the current hub container before you can start the new one via docker stop mlhub && docker rm mlhub (in case your container's name is mlhub)

from ml-hub.

stamerf avatar stamerf commented on July 19, 2024

Hi, thank you. At the same time I did this and tried to rebuild from the dockerfile. I got multiple bugs:

  1. When using original Dockerfile I got an error from the pip command when installing the crypto package. After googling it seems like there is a bug with old pip version.
    -> I fixed that by adding "RUN pip3 install --user --upgrade pip" after installting python3-dev

  2. Then I got an error when calling the signup page of jupyterhub. There is an error with jupyterhub 1.3 and tornado (see jupyterhub/nativeauthenticator#130)
    -> I fixed that by changing this line "python3 -m pip install --no-cache -I jupyterhub==1.2.1 " using a previous build of jupyterhub.

Hope this helps.

But now vs code is not working anymore...

from ml-hub.

raethlein avatar raethlein commented on July 19, 2024

Thanks for the details. It sounds like building a new version of the image would take a little bit more time. So, I suggest to use the current hub version and use the approach I described before for now :)

from ml-hub.

stamerf avatar stamerf commented on July 19, 2024

Unfortunately, that way the same error occurs. There is only a loading screen for vscode.
In terminal the supervisorctl says: vscode FATAL can't find command '/usr/local/bin/code-server'

I guess this is rather becoming a bug report than a feature request =D

from ml-hub.

raethlein avatar raethlein commented on July 19, 2024

Since it worked for me when I tested it locally, maybe it helps if you delete the started workspace container and start a fresh one from ML Hub (with the user config mounted) and try out the steps again.

from ml-hub.

stamerf avatar stamerf commented on July 19, 2024

Hi, I managed to fix it now! The problem was a zombie container still running (something like ws-mlhub-admin) which I didn't see at first. It is neccessary to delete it by hand completly because otherwise mlhub is picking it up even if you specified to use a new image-version. That solved it for me now. Thank you again for the support. This is such a great project! I love it!

from ml-hub.

raethlein avatar raethlein commented on July 19, 2024

Great, really glad to hear that it worked out! And thanks for the kind words :)

from ml-hub.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.