Add docker-compose.yml file
To run the site in docker is now a single command.
This commit is contained in:
13
index.md
13
index.md
@ -74,16 +74,11 @@ If you want to shorten this long command, you can put this code in a file such a
|
||||
## Running the site in Docker
|
||||
|
||||
You can also use Docker to directly build and run the site on your local machine. Just clone the repo and run the following from your working dir:
|
||||
```
|
||||
docker-compose up -d
|
||||
```
|
||||
The site should now be running at [http://localhost:4000/](http://localhost:4000/).
|
||||
|
||||
```
|
||||
docker build --no-cache -t mydocs .
|
||||
```
|
||||
|
||||
Once the build is complete, you can mount and run the whole site as follows:
|
||||
|
||||
```
|
||||
docker run -v "$PWD:/src" -p 4000:4000 mydocs serve -H 0.0.0.0
|
||||
```
|
||||
This is perhaps the easiest way to see how your site would actually look.
|
||||
|
||||
## Configure the sidebar
|
||||
|
Reference in New Issue
Block a user