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

Allow Remote Support for Packages #21

Closed
luni-moon opened this issue Apr 20, 2021 · 4 comments
Closed

Allow Remote Support for Packages #21

luni-moon opened this issue Apr 20, 2021 · 4 comments

Comments

@luni-moon
Copy link

I am looking for support for packages, like NODE, PIP, etc., without having to download them and put them in manually, if there even is a way. The reason for this is, I use this way to code on VSCode remotely, because the school has Linux Beta on the student chromebooks blocked/disabled, which means, I cannot use the feature to open the .deb (Debian) files for NODE.js, to download it to my chromebook, as well as there being no feature that allows you to add things like that to the remote server, even if I had the capabilities to do so. If possible, could you add preinstalled packages, like NODE and PIP, into the future updates? I know this is fully possible, since an iOS app can do it, so why can't this (I won't link the repo here, unless you ask for it)?

@AurangAsif
Copy link

You can add more Docker commands into the Dockerfile to install additional software like so:

# You can add custom software and dependencies for your environment here. Some examples:

# RUN code-server --install-extension esbenp.prettier-vscode
# RUN sudo apt-get install -y build-essential
# RUN COPY myTool /home/coder/myTool

# Install NodeJS
RUN sudo curl -fsSL https://deb.nodesource.com/setup_15.x | sudo bash -
RUN sudo apt-get install -y nodejs

Taken from https://github.com/cdr/deploy-code-server/blob/main/guides/railway.md.

For pip search 'Install pip in docker' on google for guidance

@luni-moon
Copy link
Author

Ah, ok, thank you. Sorry.

@bpmct bpmct closed this as completed Apr 21, 2021
@luni-moon
Copy link
Author

One more question, is there a way to keep all extensions installed and any code or repositories, to not be deleted when updating to a new version through remote? Also, is there any way I can get a PHP site to work as an HTML site, through Dockerfile? Thank you so much!

@AurangAsif
Copy link

  1. Persist extensions
    Basically, add commands in your Dockerfile such as
# IMPORTANT: Make sure to put any install commands after this one
# Fix permissions for code-server
RUN sudo chown -R coder:coder /home/coder/.local

# Seperate lines
RUN code-server --install-extension esbenp.prettier-vscode
RUN code-server --install-extension foo.bar

# One command
RUN code-server --install-extension esbenp.prettier-vscode --install-extension foo.bar
  1. Persist files

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

No branches or pull requests

3 participants