linuxserver / docker-code-server

GNU General Public License v3.0
1.54k stars 314 forks source link

[FEAT] Rust module for code-server #138

Closed Trevo525 closed 1 year ago

Trevo525 commented 1 year ago

Is this a new feature request?

Wanted change

I would love to see a rust module so that we could use code-server as a rust dev environment.

Reason for change

I was looking through the mods and I saw some for dotnet, golang, java, and more languages. But, I would love to have this for rust. I have recently began learning Rust and would love to have a website to be my dev environment when I change computers.

Proposed code change

I would like a new mod created for code-server to add Rust as an easy option. I looked at the dockerfile for dotnet and it looked quite complicated, but java didn't seem quite so bad. But, I am not sure how to make it myself. The official rust docker image is built from the image files here.

github-actions[bot] commented 1 year ago

Thanks for opening your first issue here! Be sure to follow the bug or feature issue templates!

aptalca commented 1 year ago

It looks like it's just a matter of installing rust/cargo from the repo. You can use the universal package installer mod for that

Trevo525 commented 1 year ago

I am away from home so I can't test this currently. But, this is what I came up with in my docker-compose. I will add it here in case someone searches rust in the issues in the future. Thanks for your response @aptalca!

    environment:
      - DOCKER_MODS=linuxserver/mods:universal-package-install
      - INSTALL_PACKAGES=git|cargo

edit: I have tested this now and it does in fact work! Thank you again!