Skip to content

Commit

Permalink
tidy up after removing antora (#78)
Browse files Browse the repository at this point in the history
* remove generate-docs plano command

* add deploy concerns, fix in examples

* add gendocs back

* updates
  • Loading branch information
pwright authored Feb 8, 2024
1 parent fa01f23 commit cbb16c6
Show file tree
Hide file tree
Showing 15 changed files with 347 additions and 795 deletions.
29 changes: 3 additions & 26 deletions .plano.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,35 +22,12 @@
@command
def generate_docs(output_dir="input", owner="skupperproject", branch="main"):
"""
Generate docs from the skupper-docs repo and config/docs-playbook.yaml.in
Generate markdown docs from the skupper-docs repo
"""

check_program("antora")
# check_program("downdoc")
print("Follow the instructions in README.")

docs_dir = get_absolute_path(f"{output_dir}/docs")
playbook_in = get_absolute_path("config/docs-playbook.yaml.in")

with working_dir():
content = read(playbook_in)
content = content.replace("@branch@", branch)
content = content.replace("@owner@", owner)
playbook = write("docs-playbook.yaml", content)

run(f"antora --fetch {playbook}")

for path in find("build", "*.html"):
move(path, f"{path}.in")

copy("build/skupper/latest/console", docs_dir)
copy("build/skupper/latest/overview", docs_dir)
copy("build/skupper/latest/cli/", docs_dir)
copy("build/skupper/latest/cli-reference", docs_dir)
copy("build/skupper/latest/cli-podman", docs_dir)
copy("build/skupper/latest/declarative", docs_dir)
copy("build/skupper/latest/troubleshooting", docs_dir)
copy("build/skupper/latest/policy", docs_dir)
copy("build/skupper/latest/operator", docs_dir)
copy("build/skupper/latest/_images", docs_dir)

@command
def generate_examples(output_dir="input"):
Expand Down
4 changes: 2 additions & 2 deletions config/examples.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,8 @@ categories:
Connect services separated by firewalls and a DMZ
- title: Database examples
description: |
With Skupper you can locate your data whereever you need it to
be, while accessing it from whereever your services are running.
With Skupper you can locate your data wherever you need it to
be, while accessing it from wherever your services are running.
examples:
- name: skupper-example-mongodb-replica-set
title: MongoDB
Expand Down
18 changes: 17 additions & 1 deletion convert-all.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,20 @@
./convert-adoc.sh cli/index.adoc cli/tokens.adoc cli/podman.adoc cli/native-security-options.adoc yaml/index.adoc operator/index.adoc console/index.adoc policy/index.adoc troubleshooting/index.adoc overview/connectivity.adoc overview/glossary.adoc overview/index.adoc overview/resources.adoc overview/routing.adoc overview/security.adoc
./convert-adoc.sh \
cli/index.adoc \
cli/tokens.adoc \
cli/podman.adoc \
cli/native-security-options.adoc \
yaml/index.adoc \
operator/index.adoc \
console/index.adoc \
policy/index.adoc \
troubleshooting/index.adoc \
overview/connectivity.adoc \
overview/glossary.adoc \
overview/index.adoc \
overview/resources.adoc \
overview/routing.adoc \
overview/security.adoc \
kubernetes/deployment-concerns.adoc

cp -r subrepos/skupper-docs/images/ input/docs/

Expand Down
729 changes: 2 additions & 727 deletions docs/docs/cli/index.html

Large diffs are not rendered by default.

18 changes: 10 additions & 8 deletions docs/docs/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -90,31 +90,32 @@ <h2>Understanding the basics</h2>
<a href="overview/security.html">Security</a>
<a href="overview/connectivity.html">Connectivity</a>
<a href="overview/routing.html">Routing</a>
<a href="/start/index.html">Getting started</a>
</nav>
</div>
<div>
<h2>Using Skupper with Kubernetes</h2>

<p>The Skupper command-line tool enables you to initialize, link, and monitor Skupper sites interactively from your development environment.</p>
<p>You can also use YAML to declaratively configure Skupper sites on Kubernetes.
<p>Learn how to use the Skupper CLI
or YAML to create Kubernetes sites.
</p>

<nav>
<a href="/start/index.html">Getting started</a>
<a href="/docs/cli/index.html">CLI guide</a>
<a href="/docs/cli/index.html#exposing-services-on-the-service-network-from-a-local-machine">Using local services (gateway)</a>
<a href="/docs/kubernetes-reference/index.html">CLI reference</a>
<a href="yaml/index.html">YAML configuration reference</a>
<a href="/docs/cli/index.html#gateway-yaml-reference">Gateway YAML reference</a>
<a href="operator/index.html">Using the Skupper operator</a>
<a href="operator/index.html">Using the Skupper Operator</a>
<a href="kubernetes/deployment-concerns.html">Advanced deployments</a>
</nav>


</div>
<div>
<h2>Using Skupper with Podman</h2>

<p>The Skupper command-line tool also works on Podman</p>
<p>You can also use YAML to declaratively configure Skupper sites on Podman.
<p>Learn how to use the Skupper CLI
or YAML to create Podman sites.
</p>

<nav>
<!-- getting started -->
Expand Down Expand Up @@ -174,6 +175,7 @@ <h2>Blog posts, articles, and videos</h2>
</div>



</div>
</section>

Expand Down
196 changes: 196 additions & 0 deletions docs/docs/kubernetes/deployment-concerns.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,196 @@
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Skupper - Deployment options on Kubernetes</title>
<meta name="description" content="Multicluster communication for Kubernetes. Skupper is a layer 7 service interconnect. It enables secure communication across Kubernetes clusters with no VPNs or special firewall rules."/>
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Lato:300,300italic,400,400italic,700,700italic|Roboto+Mono:400,400italic|Alegreya+Sans:300,300italic,400,400italic,500,500italic,700,700italic;display=optional"/>
<link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons" defer="defer"/>
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.12.0/css/all.css" defer="defer"/>
<link rel="stylesheet" href="/main.css"/>
<link rel="icon" type="image/png" sizes="32x32" href="/images/skupper-icon-32.png"/>
<link rel="icon" type="image/png" sizes="256x256" href="/images/skupper-icon-256.png"/>
<script type="text/javascript" src="/main.js" defer="defer"></script>



<script async="async" src="https://www.googletagmanager.com/gtag/js?id=UA-147980770-1"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag() { dataLayer.push(arguments); }
gtag('js', new Date());
gtag('config', 'UA-147980770-1');
</script>
</head>
<body>

<header>
<nav id="-site-nav">
<a id="-site-menu-button" style="display: none;">
<span class="material-icons">menu</span>
</a>
<div>
<div id="-left-site-nav">
<a href="/index.html" id="-logotype">
<img src="/images/skupper-logo.svg"/>
<div>Skupper</div>
</a>
<a href="/start/index.html">
<div>Getting started</div>
</a>
<a href="/examples/index.html">
<div>Examples</div>
</a>
<a href="/docs/index.html">
<div>Documentation</div>
</a>
<a href="/releases/index.html">
<div>Releases</div>
</a>
<a href="/community/index.html">
<div>Community</div>
</a>
</div>
<div id="-right-site-nav">
<a href="https://github.com/skupperproject">
<div><span class="fab fa-github fa-lg"></span> GitHub</div>
</a>
</div>
</div>
</nav>
<nav id="-path-nav"><div><a href="/docs/index.html"></a> <span class="path-separator">&#8250;</span> <a href="/docs/kubernetes/deployment-concerns.html">Deployment options on Kubernetes</a></div></nav>
<nav id="-site-menu-layer" style="display: none;">
<div>
<a href="/index.html">Home</a>
<a href="/start/index.html">Getting started</a>
<a href="/examples/index.html">Examples</a>
<a href="/docs/index.html">Documentation</a>
<a href="/community/index.html">Community</a>
</div>
</nav>
</header>


<section id="-main-and-toc">
<div>
<main>

<h1 id="deployment-options-on-kubernetes">Deployment options on Kubernetes</h1>
<p>When you create a site on Kubernetes, there are many options you can use. For example, you can set the number of pods and the resources allocated to each pod.
This guide focusses on the following goals:</p>
<ul>
<li><a href="#scaling-for-increased-traffic">Scaling for increased traffic</a></li>
<li><a href="#creating-a-high-availability-site">Creating a high availability site</a></li>
</ul>
<h2 id="scaling-for-increased-traffic">Scaling for increased traffic</h2>
<p>For optimal network latency and throughput, you can adjust the CPU allocation for the router using the <code>router-cpu</code> option.
Router CPU is the primary factor governing Skupper network performance.</p>
<p><strong>📌 NOTE</strong><br />
Increasing the number of routers does not improve network performance. An incoming router-to-router link is associated with just one active router. Additional routers do not receive traffic while that router is responding</p>
<ol>
<li><p>Determine the router CPU allocation you require.</p>
<p>By default, the router CPU allocation is <code>BestEffort</code> as described in <a href="https://kubernetes.io/docs/concepts/workloads/pods/pod-qos/#besteffort">Pod Quality of Service Classes</a>.</p>
<p>Consider the following CPU allocation options:</p>
</li>
</ol>
<table>
<thead>
<tr>
<th>Router CPU</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td>1</td>
<td>Helps avoid issues with <code>BestEffort</code> on low resource clusters</td>
</tr>
<tr>
<td>2</td>
<td>Suitable for production environments</td>
</tr>
<tr>
<td>5</td>
<td>Maximum performance</td>
</tr>
</tbody>
</table>
<ol start="2">
<li><p>If you are using the Skupper CLI, set the CPU allocation for the router using the <code>--router-cpu</code> option. For example:</p>
<pre><code class="language-bash">$ skupper init --router-cpu 2
</code></pre>
</li>
<li><p>If you are using YAML, set the CPU allocation for the router by setting a value for the <code>router-cpu</code> attribute. For example:</p>
<pre><code class="language-YAML">apiVersion: v1
kind: ConfigMap
metadata:
name: &quot;skupper-site&quot;
data:
name: &quot;my-site&quot;
router-cpu: 2
</code></pre>
</li>
</ol>
<h2 id="creating-a-high-availability-site">Creating a high availability site</h2>
<p>By default, Kubernetes restarts any router that becomes unresponsive.
(If you encounter router restarts, consider <a href="#scaling-for-increased-traffic">Scaling for increased traffic</a> in order to improve responsiveness.)</p>
<p>If the cluster where you are running Skupper is very busy, it may take time for Kubernetes to schedule a new router pod. You can &quot;preschedule&quot; a backup router by deploying two routers in a site.</p>
<ol>
<li><p>If you are using the Skupper CLI, set the number of routers to <code>2</code> using the <code>--routers</code> option:</p>
<pre><code class="language-bash">$ skupper init --routers 2
</code></pre>
</li>
<li><p>If you are using YAML, set the number of routers to <code>2</code> by setting the <code>routers</code> attribute:</p>
<pre><code class="language-YAML">apiVersion: v1
kind: ConfigMap
metadata:
name: &quot;skupper-site&quot;
data:
name: &quot;my-site&quot;
routers: 2
</code></pre>
</li>
</ol>
<p>Setting the number of routers to more than two does not provide increased availability and can adversely affect performance.</p>
<p>Note that clients must reconnect when a router restarts or traffic is
redirected to a backup router.</p>


</main>
<nav id="-toc">
<h4>Contents</h4>
<div></div>
</nav>
</div>
</section>

<footer>
<div>
<div>
<p><a href="https://twitter.com/SkupperIO"><span class="fab fa-twitter fa-lg"></span> Twitter</a></p>
<p><a href="https://www.youtube.com/channel/UCQxHN2Qq8koCatcmKCJ4OEA"><span class="fab fa-youtube fa-lg"></span> YouTube</a></p>
<!-- <p><a href="https://stackoverflow.com/questions/tagged/skupper"><span class="fab fa-stack-overflow fa-lg"></span> Stack Overflow</a></p> -->
<p><a href="https://groups.google.com/forum/#!forum/skupper"><span class="fas fa-envelope fa-lg"></span> Mailing list</a></p>
<p><a href="https://github.com/skupperproject"><span class="fab fa-github fa-lg"></span> GitHub</a></p>
</div>
<div>
<h4>Skupper - Multicloud communication for Kubernetes</h4>
<p>Skupper enables secure communication across Kubernetes
clusters with no VPNs or special firewall rules</p>
<p>Copyright &#169; 2023 the Skupper authors</p>
</div>
<div>
<p>All code and documentation is licensed under
the <a href="https://www.apache.org/licenses/LICENSE-2.0">Apache
License version 2.0</a></p>
<p>Marks may be trademarks or registered trademarks of their
respective owners</p>
<p><a href="/site.html">About this site</a></p>
</div>
</div>
</footer>



</body>
</html>
4 changes: 2 additions & 2 deletions docs/examples/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -242,8 +242,8 @@ <h3><a href="https://github.com/skupperproject/skupper-example-dmz">DMZ</a></h3>

<h2 id="database-examples">Database examples</h2>

<p>With Skupper you can locate your data whereever you need it to
be, while accessing it from whereever your services are running.
<p>With Skupper you can locate your data wherever you need it to
be, while accessing it from wherever your services are running.
</p>

<div class="examples">
Expand Down
18 changes: 10 additions & 8 deletions input/docs/index.html.in
Original file line number Diff line number Diff line change
Expand Up @@ -19,31 +19,32 @@ extra_headers: <link rel="stylesheet" href="index.css" type="text/css" async="as
<a href="overview/security.html">Security</a>
<a href="overview/connectivity.html">Connectivity</a>
<a href="overview/routing.html">Routing</a>
<a href="/start/index.html">Getting started</a>
</nav>
</div>
<div>
<h2>Using Skupper with Kubernetes</h2>

<p>The Skupper command-line tool enables you to initialize, link, and monitor Skupper sites interactively from your development environment.</p>
<p>You can also use YAML to declaratively configure Skupper sites on Kubernetes.
<p>Learn how to use the Skupper CLI
or YAML to create Kubernetes sites.
</p>

<nav>
<a href="/start/index.html">Getting started</a>
<a href="/docs/cli/index.html">CLI guide</a>
<a href="/docs/cli/index.html#exposing-services-on-the-service-network-from-a-local-machine">Using local services (gateway)</a>
<a href="/docs/kubernetes-reference/index.html">CLI reference</a>
<a href="yaml/index.html">YAML configuration reference</a>
<a href="/docs/cli/index.html#gateway-yaml-reference">Gateway YAML reference</a>
<a href="operator/index.html">Using the Skupper operator</a>
<a href="operator/index.html">Using the Skupper Operator</a>
<a href="kubernetes/deployment-concerns.html">Advanced deployments</a>
</nav>


</div>
<div>
<h2>Using Skupper with Podman</h2>

<p>The Skupper command-line tool also works on Podman</p>
<p>You can also use YAML to declaratively configure Skupper sites on Podman.
<p>Learn how to use the Skupper CLI
or YAML to create Podman sites.
</p>

<nav>
<!-- getting started -->
Expand Down Expand Up @@ -101,3 +102,4 @@ extra_headers: <link rel="stylesheet" href="index.css" type="text/css" async="as
<a href="https://www.youtube.com/watch?v=FPsUgxmj25s">HTTP load-balancing with Skupper across OpenShift clusters</a>
</nav>
</div>

Loading

0 comments on commit cbb16c6

Please sign in to comment.