zeus
3 years ago
7 changed files with 89 additions and 4 deletions
@ -1,2 +1,17 @@ |
|||
# Documentation |
|||
# swarmlab docs |
|||
|
|||
A [swarmlab.io](http://www.swarmlab.io) sidecar container. |
|||
|
|||
Documentation is a multi-repository site generator (Antora based) |
|||
|
|||
|
|||
## Build from git |
|||
|
|||
> git clone https://git.swarmlab.io:3000/docs/Documentation.git |
|||
> |
|||
> cd docs |
|||
> ./build.sh |
|||
> |
|||
> |
|||
|
|||
|
|||
|
@ -0,0 +1,5 @@ |
|||
docker stop swarmlab-documentation |
|||
docker container rm swarmlab-documentation |
|||
docker pull hub.swarmlab.io:5480/antora |
|||
|
|||
docker run -ti --name swarmlab-documentation -v $PWD/docs:/antora hub.swarmlab.io:5480/antora /bin/sh -c "DOCSEARCH_ENABLED=true DOCSEARCH_ENGINE=lunr DOCSEARCH_INDEX_VERSION=latest NODE_PATH=/usr/local/lib/node_modules:\$NODE_PATH exec sh -c '/antora/run/build-intro.sh'" |
@ -0,0 +1,11 @@ |
|||
docker stop swarmlab-documentation |
|||
docker container rm swarmlab-documentation |
|||
docker pull hub.swarmlab.io:5480/antora |
|||
|
|||
antora --fetch site.yml |
|||
antora site.yml |
|||
ifconfig |
|||
http-server build/site -c-1 |
|||
|
|||
|
|||
docker run -ti --name swarmlab-documentation -v $PWD/docs:/antora hub.swarmlab.io:5480/antora /bin/sh -c "DOCSEARCH_ENABLED=true DOCSEARCH_ENGINE=lunr DOCSEARCH_INDEX_VERSION=latest NODE_PATH=/usr/local/lib/node_modules:\$NODE_PATH exec sh -c 'build.sh'" |
@ -0,0 +1,21 @@ |
|||
# This file represents "software". |
|||
# This file helps show that documentation files can be in the same repository as software. |
|||
|
|||
rescue => ex |
|||
begin |
|||
context = %(asciidoctor: FAILED: #{attrs['docfile'] || '<stdin>'}: Failed to load AsciiDoc document) |
|||
if ex.respond_to? :exception |
|||
# The original message must be explicitely preserved when wrapping a Ruby exception |
|||
wrapped_ex = ex.exception %(#{context} - #{ex.message}) |
|||
# JRuby automatically sets backtrace, but not MRI |
|||
wrapped_ex.set_backtrace ex.backtrace |
|||
else |
|||
# Likely a Java exception class |
|||
wrapped_ex = ex.class.new context, ex |
|||
wrapped_ex.stack_trace = ex.stack_trace |
|||
end |
|||
rescue |
|||
wrapped_ex = ex |
|||
end |
|||
raise wrapped_ex |
|||
end |
@ -0,0 +1,4 @@ |
|||
antora --fetch /antora/site-intro.yml |
|||
antora /antora/site-intro.yml |
|||
ifconfig |
|||
http-server build/site -c-1 |
@ -0,0 +1,21 @@ |
|||
site: |
|||
title: Swarmlab sec-intro |
|||
url: http://docs.swarmlab.io/SwarmLab-HowTos/swarmlab/docs |
|||
start_page: swarmlab::index.adoc |
|||
content: |
|||
sources: |
|||
- url: https://git.swarmlab.io:3000/docs/Documentation.git |
|||
branches: master |
|||
start_path: docs |
|||
ui: |
|||
bundle: |
|||
url: https://git.swarmlab.io:3000/docs/docs/raw/branch/master/ui-bundle.zip |
|||
snapshot: true |
|||
supplemental_files: ./supplemental-ui |
|||
asciidoc: |
|||
attributes: |
|||
:plantuml-server-url: http://www.plantuml.com/plantuml |
|||
extensions: |
|||
- '@djencks/asciidoctor-mathjax' |
|||
- asciidoctor-plantuml |
|||
|
Loading…
Reference in new issue