2018-11-06 16:29:42 +03:00
|
|
|
# Official ReDoc Docker Image
|
2018-06-25 14:10:29 +03:00
|
|
|
|
|
|
|
## Usage
|
|
|
|
|
|
|
|
Serve remote spec by URL:
|
|
|
|
|
|
|
|
docker run -it --rm -p 80:80 \
|
2019-03-11 10:32:55 +03:00
|
|
|
-e SPEC_URL='http://localhost:8000/swagger.yaml' redocly/redoc
|
2018-06-25 14:10:29 +03:00
|
|
|
|
|
|
|
Serve local file:
|
|
|
|
|
|
|
|
docker run -it --rm -p 80:80 \
|
2019-03-11 10:32:55 +03:00
|
|
|
-v $(pwd)/demo/swagger.yaml:/usr/share/nginx/html/swagger.yaml \
|
|
|
|
-e SPEC_URL=swagger.yaml redocly/redoc
|
2018-06-25 14:10:29 +03:00
|
|
|
|
|
|
|
## Runtime configuration options
|
|
|
|
|
|
|
|
- `PAGE_TITLE` (default `"ReDoc"`) - page title
|
|
|
|
- `PAGE_FAVICON` (default `"favicon.png"`) - URL to page favicon
|
|
|
|
- `SPEC_URL` (default `"http://petstore.swagger.io/v2/swagger.json"`) - URL to spec
|
|
|
|
- `PORT` (default `80`) - nginx port
|
2019-06-04 15:47:22 +03:00
|
|
|
- `REDOC_OPTIONS` - [`<redoc>` tag attributes](https://github.com/Redocly/redoc#redoc-tag-attributes)
|
2018-11-06 16:29:42 +03:00
|
|
|
|
|
|
|
## Build
|
|
|
|
|
2019-03-11 10:32:55 +03:00
|
|
|
docker build -t redocly/redoc .
|