-
Notifications
You must be signed in to change notification settings - Fork 0
Home
Welcome to the cooperative-perception-core wiki!
We develop this project on Linux (Ubuntu and Fedora) using Visual Studio Code (VS Code) and development containers (devcontainers). This development environment is also working on Mac OS X with Apple Silicon. You are of course free to develop using any environment you want as long as the code you produce meets our conventions and standards. Note, however, that we will not track any configurations besides those for VS Code, devcontainers, or configurations common to all environments.
Before we can configure VS Code to use the devcontainer, we must install a container engine. Podman is our engine of choice, but Docker should work too. The installation process is slightly different for each system, so check out the Podman docs and Docker docs for instructions. We recommend using rootless mode for added security.
You can find the download link and installation instructions on the official download page.
VS Code by itself is essentially a fancy text editor, but we can install extensions to add features. The only extension we need to install right now is called Dev Containers. To do so, follow these steps:
- Open VS Code.
- Open the Extensions tab.
- In the Search Extensions in Marketplace box, type
dev containers
. - Click on the Dev Containers extension by Microsoft.
- Click the Install button.
If you plan on using Docker as your container engine, then you are all set. If you are using Podman, you need to tell VS Code about that. To update the Dev Container settings, follow these steps:
- Open VS Code.
- Click on File.
- Hover your mouse over Preferences.
- Click Settings.
- In the Search settings box, type
docker
. You should see at least two settings. We are concerned with Docker Compose Path and Docker Path. - Replace the text in Docker Compose Path with
podman-compose
. - Replace the text in Docker Path with
podman
. - Close VS Code and reopen it for the settings to take effect.
After cloning our repository, you can open the project in VS Code by opening the cooperative_perception_core
folder. After opening the project, VS Code might automatically ask if you want to reopen the project in a devcontainer. If you agree, VS Code will create the devcontainer image and reopen the project in it.
If VS Code does not automatically prompt you, you can manually reopen the project in a devcontainer. To do so, follow these steps:
- Click on the blue square icon in the lower left corner of the VS Code window. If you hover over it, a tool tip box should appear that says, "Open a Remote Window."
- In the drop down list, select Reopen in Container. VS code will create the devcontainer image and reopen the project in it.
- You are ready to start developing in the container.