Skip to content

Commit 3530c61

Browse files
chore: allow make docs to be run in container (#12563)
1 parent a8a8b6d commit 3530c61

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

Makefile

+6
Original file line numberDiff line numberDiff line change
@@ -804,7 +804,13 @@ check-format: format
804804
# Documentation related commands
805805

806806
doc: ## Generates the config file documentation
807+
ifeq ($(BUILD_IN_CONTAINER),true)
808+
$(SUDO) docker run $(RM) $(TTY) -i \
809+
-v $(shell pwd):/src/loki$(MOUNT_FLAGS) \
810+
$(IMAGE_PREFIX)/loki-build-image:$(BUILD_IMAGE_VERSION) $@;
811+
else
807812
go run ./tools/doc-generator $(DOC_FLAGS_TEMPLATE) > $(DOC_FLAGS)
813+
endif
808814

809815
docs: doc
810816

0 commit comments

Comments
 (0)