mirror of
https://github.com/grafana/grafana.git
synced 2024-12-22 23:23:49 -06:00
Docs: updated cmd to build docs locally to generate docs prior to building site. (#28371)
* added instructions so we generate docs prior to building them. * replaced ci script. * improved according to feedback.
This commit is contained in:
parent
2aafa39879
commit
0bb33839f5
3
.gitignore
vendored
3
.gitignore
vendored
@ -118,3 +118,6 @@ compilation-stats.json
|
||||
|
||||
# report dumping the whole system env
|
||||
/report.*.json
|
||||
|
||||
# auto generated front end docs
|
||||
/docs/sources/packages_api/*
|
@ -1,14 +1,23 @@
|
||||
.PHONY: docs docs-test
|
||||
.PHONY: docs docs-test docs-no-pull docs-generate-frontend docs-no-generate-frontend
|
||||
|
||||
IMAGE = grafana/docs-base:latest
|
||||
|
||||
docs:
|
||||
docker pull ${IMAGE}
|
||||
docs-generate-frontend:
|
||||
yarn install --pure-lockfile
|
||||
yarn run packages:build
|
||||
yarn run packages:docsExtract
|
||||
yarn run packages:docsToMarkdown
|
||||
yarn run packages:clean
|
||||
|
||||
docs-no-generate-frontend:
|
||||
docker run -v $(shell pwd)/sources:/hugo/content/docs/grafana/latest -p 3002:3002 --rm -it $(IMAGE) /bin/bash -c 'make server'
|
||||
|
||||
docs-no-pull:
|
||||
docs: docs-generate-frontend
|
||||
docker pull $(IMAGE)
|
||||
docker run -v $(shell pwd)/sources:/hugo/content/docs/grafana/latest -p 3002:3002 --rm -it $(IMAGE) /bin/bash -c 'make server'
|
||||
|
||||
docs-test:
|
||||
docker pull ${IMAGE}
|
||||
docs-no-pull: docs-generate-frontend docs-no-generate-frontend
|
||||
|
||||
docs-test: docs-generate-frontend
|
||||
docker pull $(IMAGE)
|
||||
docker run -v $(shell pwd)/sources:/hugo/content/docs/grafana/latest --rm -it $(IMAGE) /bin/bash -c 'make prod'
|
||||
|
@ -5,6 +5,7 @@ When you contribute to documentation, it is a good practice to build the docs on
|
||||
## Requirements
|
||||
|
||||
Docker >= 2.1.0.3
|
||||
Yarn >= 1.22.4
|
||||
|
||||
## Build the doc site
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user