This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Choose the best response for each question.
After you've added a dev container configuration to a project, how do you open that project in the container?
The project automatically opens in the container.
Select Add Development Configuration Files from the Command Palette.
Use the Reopen in Container option in Visual Studio Code.
Start the project from the terminal.
How do you run additional commands after the dev container has been created?
Use the postCreateCommand property in the devcontainer.json
Use the post-install hook in the devcontainer.json
Specify the command in the Dockerfile
Pass the postCreate flag to the build command.
How would you install additional software in a container so that it persists your changes even after rebuilding?
Use an apt-get command in the devcontainer.json file's postSetupCommand option.
apt-get
postSetupCommand
Use the apt-get command in the Dockerfile's postSetupCommand option.
Install the software after the container loads via the terminal.
Use a Dev Container Feature.
You must answer all questions before checking your work.
Was this page helpful?