Skip to content

Ealenn/codespaces

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🧑‍💻 Codespace - Development Environment

GitHub stars Docker Pulls

A modern developer-friendly environment optimized for containers, VS Code Remote Containers, and GitHub Codespaces.

📦 Environment

🖥 Terminal

  • ZSH & Oh-My-ZSH Zsh is a shell designed for interactive use, although it is also a powerful scripting language.
  • Starship The minimal, blazing-fast, and infinitely customizable prompt for any shell!
  • LSD Colorizes the ls output with color and icons.
  • TheFuck The Fuck is a magnificent app, that corrects errors in previous console commands.
  • JQ jq is a lightweight and flexible command-line JSON processor.
  • fd-find A simple, fast and user-friendly alternative to 'find'

🔧 Tools

  • Vim Vim is a highly configurable text editor built to make creating and changing any kind of text very efficient.
  • NeoVim Vim-fork focused on extensibility and usability
    • ecosse3/nvim A non-minimal Neovim config built to work most efficiently with Frontend Development
  • LazyDocker & LazyGit The lazier way to manage everything in docker or git
  • But also git, gpg, curl, wget, etc.

🧑‍💻 Languages & Runtimes

  • Go A simple, fast, and reliable language designed for scalable and efficient software development.
  • Rust A language empowering everyone to build reliable and efficient software.
  • NVM with Node LTS installed by default. NVM is a version manager for NodeJS.
  • ZX Bash is great, but when it comes to writing scripts, people usually choose a more convenient programming language.
  • Python3 Python is a programming language that lets you work quickly and integrate systems more effectively.
    • UV An extremely fast Python package and project manager, written in Rust.

🐳 Docker-in-Docker

  • Full Docker CLI and Compose support inside container
  • docker.sock ready for volume mount

💡 Remote Containers (VS Code)

Remote Container

This image is compatible with VS Code Remote Containers, enabling a full development experience using a containerized environment.

Example .devcontainer/devcontainer.json:

{
  "name": "codespaces",
  "image": "ealen/codespaces",
  "extensions": [
    "golang.go",
    "dbaeumer.vscode-eslint",
    "oouo-diogo-perdigao.docthis",
    "bungcip.better-toml",
    "redhat.vscode-yaml",
    "yzhang.markdown-all-in-one",
    "editorconfig.editorconfig",
    "gruntfuggly.todo-tree",
    "eamodio.gitlens",
    "naumovs.color-highlight",
    "vscode-icons-team.vscode-icons",
    "ms-azuretools.vscode-docker"
  ],
  "settings": {
    "workbench.iconTheme": "vscode-icons",
    "editor.fontFamily": "Consolas, 'Courier New', monospace, hack, 'Hack Nerd Font Mono'",
    "terminal.integrated.fontFamily": "Consolas, 'Hack Nerd Font Mono'",
    "terminal.integrated.fontSize": 14,
    "files.autoSave": "onFocusChange",
    "editor.tabSize": 2,
    "eslint.format.enable": true,
  },
  "mounts": [
    "source=/home/YOUR_USER/.ssh,target=/home/ubuntu/.ssh,type=bind,readonly",
    "source=/home/YOUR_USER/.gnupg,target=/home/ubuntu/.gnupg,type=bind,readonly",
    "source=/var/run/docker.sock,target=/var/run/docker.sock,type=bind"
  ]
}

💡 You must install a Nerd Font such as Hack Nerd Font Mono

🐋 Raw Docker Usage

NVIM

You can run the image without VS Code using standard Docker commands.

Example: Run with persistent volumes and access to Docker

docker run -it --rm \
  -v ~/.ssh:/home/ubuntu/.ssh:ro \
  -v ~/.gnupg:/home/ubuntu/.gnupg:ro \
  -v /var/run/docker.sock:/var/run/docker.sock \
  -v $(pwd):/workspace \
  -e PUID=$(id -u) \
  -e PGID=$(id -g) \
  -w /workspace \
  ealen/codespaces

You can now launch nvim from inside the container, and work on your project directly from the mounted volume.

💡 Note: The Codespaces Docker image is also available on GitHub Container Registry.

If your company restricts access to docker.io, you can use the GitHub-hosted image instead by replacing ealen/codespaces with ghcr.io/ealenn/codespaces.

alias codespaces='docker run -it --rm \
  -v "$HOME/.ssh:/home/ubuntu/.ssh:ro" \
  -v "$HOME/.gnupg:/home/ubuntu/.gnupg:ro" \
  -v "/var/run/docker.sock:/var/run/docker.sock" \
  -v "$PWD:/workspace" \
  -w /workspace \
  ghcr.io/ealenn/codespaces'

💻 GitHub Codespaces Support

This image is fully compatible with GitHub Codespaces!

To use:

  1. Create a .devcontainer/devcontainer.json in your repo (as shown above).
  2. Push to GitHub.
  3. Open the repo in Codespaces.

That's it! You'll get a fully functional container with Docker, ZSH, Starship, Go, Rust, Node, and Python already configured.

📁 Example Repo

You can find a working example inside the example/ folder.

About

Dev containers for Go, Rust, TypeScript, and Python projects with ZSH, Starship, and more...

Topics

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors 3

  •  
  •  
  •