Skip to content

Patrick-Pataky/cs200_docker

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

26 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CS200

How to use

Initial setup

Go to the directory where you want to work on the labs and run the following command:

curl -LO https://github.com/Patrick-Pataky/cs200_docker/releases/latest/download/default.devcontainer.json
mv default.devcontainer.json .devcontainer.json

docker pull ppataky5/cs200:latest

And finally, open the folder in VSCode.

code .

Install docker desktop and devcontainer extension for VSCode

Launch the devcontainer

  • Hit CTRL+SHIFT+P and type Dev Containers: Rebuild and Reopen in Container

This should start the container and open the project in VSCode.

Working with the container

By default, the container will start in the cs200 directory, which contains the labs folder.

For lab1, two versions are available: lab1 and lab1_fast. You can work on both, as lab1_fast is simply a symlink to lab1 with an accelerated simulation. Symlink means that any changes made in lab1 will be reflected in lab1_fast and vice versa.

!!! Important Do NOT modify the lab1_fast directory while the container is NOT running, as it will break the symlink. !!!

Good luck!

(Optional) Building the container from source

First, add lab files to the repository, under the src folder, from Moodle. You should follow the following structure:

src
├── Dockerfile
├── lab1
│   └── ...
├── lab2
│   └── ...
└── lab3
    └── ...

Then, build the container:

cd src
docker build -t cs200 .

Note that this will take a while, especially the RISC-V toolchain installation.

Finally, update the .devcontainer.json file to use the local image:

"image": "cs200",

About

Simple docker configuration for the cs200 course

Resources

Stars

Watchers

Forks

Packages

No packages published