MkDocs plugin for uploading markdown documentation to Confluence via Confluence REST API
Go to file
Nikolai Rodionov 8efe5ceda6 Refactoring (#1)
This PR is very far from perfect, and there are some things that do not work yet, but I think it's good enough to merge

Co-authored-by: Shyam Saraswati <shyam.saraswati@gmail.com>
Co-authored-by: Nikolai Rodionov <nikolai.rodionov@grandcentrix.net>
Reviewed-on: #1
2023-02-24 08:40:21 +00:00
.github/workflows Refactoring (#1) 2023-02-24 08:40:21 +00:00
example Refactoring (#1) 2023-02-24 08:40:21 +00:00
mkdocs_with_confluence Refactoring (#1) 2023-02-24 08:40:21 +00:00
.dockerignore Refactoring (#1) 2023-02-24 08:40:21 +00:00
.gitignore Refactoring (#1) 2023-02-24 08:40:21 +00:00
.sops.yaml Refactoring (#1) 2023-02-24 08:40:21 +00:00
LICENSE Update README, LICENSE, and yaml workflow files 2021-04-23 20:04:21 +02:00
Makefile Refactoring (#1) 2023-02-24 08:40:21 +00:00
README.md Refactoring (#1) 2023-02-24 08:40:21 +00:00
poetry.lock Refactoring (#1) 2023-02-24 08:40:21 +00:00
pyproject.toml Refactoring (#1) 2023-02-24 08:40:21 +00:00

README.md

mkdocs-with-confluence

MkDocs plugin that converts markdown pages into confluence markup and export it to the Confluence page

How to use

To enable plugin, you need to set the MKDOCS_TO_CONFLUENCE environment variable.

export MKDOCS_TO_CONFLUENCE=1

By default the dry-run mode is turned off. If you wan't to enable it, you can use the config file, ot the MKDOCS_TO_CONFLUENCE_DRY_RUN environment variable

export MKDOCS_TO_CONFLUENCE_DRY_RUN=1

Setup

Install the plugin using pip:

pip install mkdocs-with-confluence

Activate the plugin in mkdocs.yml:

plugins:
  - search
  - mkdocs-with-confluence

More information about plugins in the MkDocs documentation: mkdocs-plugins.

Usage

Use following config and adjust it according to your needs:

  - mkdocs-with-confluence:
        host_url: https://<YOUR_CONFLUENCE_DOMAIN>/rest/api/content
        space: <YOUR_SPACE>
        parent_page_name: <YOUR_ROOT_PARENT_PAGE>
        username: <YOUR_USERNAME_TO_CONFLUENCE>
        password: <YOUR_PASSWORD_TO_CONFLUENCE>
        dryrun: true

Parameters:

Requirements

  • md2cf
  • mimetypes
  • mistune