Set up a self-contained development environment for CAP Node.js
- How to use a development container in VS Code
- What GitHub Codespaces are and how they can be useful
Prerequisites
- Either: VS Code installed, with the Dev Containers extension, and also a container manager installed, such as Docker Desktop or Podman
- Or: a free GitHub account (to use Codespaces), and a modern Web browser
One thing that’s consistent about software development over the recent decades … is change. Different tools, editors and command line facilities come along with new approaches, frameworks and techniques. Today, the pace of that change is only increasing, and as developers we are required to work out what tools we need, install them, keep them up to date and prevent them from clashing with each other or with existing software we have on our machines.
One solution to all those challenges is development containers, and in this tutorial you’ll use a development container definition to get the perfect setup for CAP Node.js development with no effort and no footprint left on your machine. All you need are some basic building blocks - VS Code and a container runtime such as Docker Desktop or Podman. We’ll call that Option 1. What’s more, you can even avoid installing anything on your machine, and just use GitHub’s Codespaces instead. We’ll call that Option 2.
There’s a bonus advantage of going with one of these container-based options: the command line environment you will have is the same as the environment that exists in pretty much all cloud scenarios - generally, a Unix style operating system with a Unix style shell, and specifically, a Linux distribution with a Bash shell.
Of course, if you prefer to continue to manage your own developer tools installation on your own machine at the native OS level, that’s also perfectly fine. Let’s call that Option 0 :-).
Regardless of which option you choose, we recommend you still read through all the steps in this tutorial, to answer to question at the end.


