What is the best way to keep installed system packages?
I use ubuntu as my base docker image. In a lot of workspaces I install additional system packages via apt.
When I use codespaces and install packages there, they stay on even after a restart.
What is the best way to keep them?
One way would be to use the personalized file right? Any other/better way without user interference?
6 Replies
<#1215084359061864458>
Category
Help needed
Product
Coder OSS (v2)
Platform
Linux
Logs
Please post any relevant logs/error messages.
Bump
Why don't you build a custom base image with your images?
I already do that, but for some projects you a developer needs package XYZ and another needs ZYX. It would be nice, if the installed packages could be kept. Just like codespaces does it
If its a docker workspace, you can mount volumes at
/usr
, /etc/
etc to persist them. This will persist the packages installed by apt
.I have a template where I am doing this. See https://github.com/matifali/coder-templates/blob/main/deeplearning%2Fmain.tf for reference.
GitHub
coder-templates/deeplearning/main.tf at main · matifali/coder-templ...
Coder OSS templates. Contribute to matifali/coder-templates development by creating an account on GitHub.