MartijnVisser commented on code in PR #19571: URL: https://github.com/apache/flink/pull/19571#discussion_r857641210
########## docs/README.md: ########## @@ -32,6 +32,79 @@ $ ./build_docs.sh The site can be viewed at http://localhost:1313/ +## Include externally hosted documentation + +With the ongoing efforts to move Flink's connectors from this repository to individual, dedicated +repositories, this also requires the documentation to be hosted outside this repo. However, +we still want to serve all documentation as a whole on the Flink documentation website. + +In order to achieve this, we're using [Hugo Modules.](https://gohugo.io/hugo-modules/configuration/) +to create a virtual filesystem. + +Adding new externally hosted documentation requires the following steps to be taken: + +1. (If necessary) Move the existing documentation to the new repository +2. In this new repository, in the `docs` folder, create a file `go.mod` containing: + +```go +module github.com/apache/flink-connector-<repositoryname>/docs + +go 1.18 +``` + +Replace <repositoryname> with the name of your repository. +See https://github.com/apache/flink-connector-elasticsearch/tree/main/docs/go.mod for an example. +3. In this new repository, in the `docs` folder, create a `config.toml` file containing: + +```yaml +module: + mounts: + - source: content/docs/connectors/datastream/<filename>.md + target: content/docs/connectors/datastream/<filename>.md Review Comment: I do think it could be generalized to just have a folder for English and one for Chinese content -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@flink.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org