Sign inSign up

qraynaud/workenv

By qraynaud

Updated almost 2 years ago

Work environment to code from it or remotely (using SSH or openvscode-server).

Image
0

2.3K

qraynaud/workenv repository overview

workenv

Derived from the excellent openvscode-server image. Also add an openssh-server and most of my tools to work.

I might split this image in 2 later on to have one with my specifics and one more generic for easy reuse by others individuals.

You can find the repository with all the files that were used to generate this image here.

Getting started

Environment variables

Here are the useful env variables you should be aware of:

VariableDefault valueDoc
USER_LOGINcodeThe name your user should have in the env
USER_UID1000The UID your user uses
USER_GID1000The GID your user uses
USER_HOME/home/${USER_LOGIN}The path to your user's home folder
TZUpdate the timezone to use in the env

Important note: the environment is initialized only once at first start, after that those are ignored

Volumes to mount

Here are the interesting volumes you might want to bind in the container:

Container PathHost PathModeDoc
$USER_HOME/path/to/your/user/homerwThe GID your user uses
/etc/ssh/keys/path/to/your/server/ssh/keysro/rwIf the folder is empty, it will generate keys there at first boot (needs rw). Otherwise, it will read keys ssh_host_[rsa|ecdsa|ed25519]_key[.pub|] from the folder (ro is okay).
/etc/localtime/etc/localtimeroMatch the localtime of your host in the VM
/var/run/docker.sock/var/run/docker.sockro(optional) If you want access to your docker env, bind this one
Important ports

The ports that you need to handle to access the different services are:

Container portService typeDoc
22SSHAccess your VM through SSH
3000HTTPAccess openvscode-server (note: this route is not secure and you will need to handle authentication with a reverse-proxy or a similar system)

Changelog

v1.0.2
  • Try to fix issues with vscode sometimes not finding its own sockets
v1.0.1
  • Add proper support for the TZ env variable

Tag summary

Content type

Image

Digest

sha256:6b7c02f2c

Size

616.3 MB

Last updated

almost 2 years ago

docker pull qraynaud/workenv