This is my base workspace for all my projects. It contains a portable docker environment with vscode tunnels already configured, provisioned using terraform.
Create a new workspace using the pocketenv command line tool:
pocketenv init -t tsirysndr/base-workspace
pocketenv up
Or using terraform:
git clone https://github.com/tsirysndr/base-workspace.git
cd base-workspace
terraform init
terraform apply
A new Docker container will be created with the name base-workspace
with pkgx, oh-my-posh, atuin and vscode server installed.
To connect to the environment, run:
docker logs base-workspace
and follow the vscode tunnel instructions.
You can also enter to the environment using:
docker exec -it base-workspace bash
oh-my-posh and atuin are already configured in the environment.
Name | Description |
---|---|
devbox | devbox environment with vscode tunnels configured. |
devenv | devenv environment with vscode tunnels configured. |
flox | flox environment with vscode tunnels configured. |
hombrew | homebrew environment with vscode tunnels configured. |
nix | nix environment with vscode tunnels configured. |
pkgx | pkgx environment with vscode tunnels configured. |
default | base environment with vscode tunnels configured. |
Name | Description | Type | Default |
---|---|---|---|
context | Docker build context to use | string |
null |
hostname | Hostname to use | string |
null |
image | Docker image to use, required if context is not set | string |
ghcr.io/pocketenv-io/pkgx:main |
packages | Packages to install | list(string) |
[] |
user | User to create | string |
coder |
volumes | Volumes to mount | map(string) |
{ base-workspace = "/home/coder" } |
workspace_name | Name of the workspace | string |
base-workspace |
Name | Description | Type |
---|---|---|
container_id | Docker container id | string |
devbox.tfvars
workspace_name = "devbox-workspace"
user = "coder"
context = "./devbox"
volumes = {
devbox-workspace = "/home/coder"
devbox-nix = "/nix"
}
devenv.tfvars
workspace_name = "devenv-workspace"
user = "coder"
context = "./devenv"
volumes = {
devenv-workspace = "/home/coder"
devenv-nix = "/nix"
}
flox.tfvars
workspace_name = "flox-workspace"
user = "coder"
context = "./flox"
volumes = {
flox-workspace = "/home/coder"
flox-nix = "/nix"
}
homebrew.tfvars
workspace_name = "brew-workspace"
packages = [
"jq",
"gh"
]
user = "coder"
context = "./homebrew"
volumes = {
brew-workspace = "/home/coder"
linuxbrew = "/home/linuxbrew/.linuxbrew"
}
pkgx.tfvars
workspace_name = "pkgx-workspace"
packages = [
"jq",
"gh"
]
user = "coder"
context = "./pkgx"
volumes = {
pkgx-workspace = "/home/coder"
}
This project is licensed under the MIT License.