Skip to content

Commit

Permalink
Collection renamed from network to skupper (#33)
Browse files Browse the repository at this point in the history
* Collection renamed from network to skupper

* Renamed all variables to comply with Ansible lint
* Renamed skupper role to skupper_deploy
* Added e2e test
* Added argument specs for all roles
* Improved documentation for modules and roles
* Removed collection inner docs dir
* Updated unit tests
* Updated README files

* Renamed roles and variables

* skupper_deploy is now skupper_setup
* skupper_delete is now skupper_teardown
* skupper_service_services is now skupper_service_list
* skupper_link_links is now skupper_link_list
  • Loading branch information
fgiorgetti authored Apr 1, 2024
1 parent ff97635 commit 4cd639d
Show file tree
Hide file tree
Showing 235 changed files with 5,686 additions and 5,555 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ jobs:
uses: ansible/ansible-publish-action@v1.0.0
with:
api_key: ${{ secrets.ANSIBLE_API_KEY }}
src_path: /github/workspace/skupper/network
src_path: /github/workspace/skupper/skupper
2 changes: 1 addition & 1 deletion .github/workflows/pulls.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,5 @@ jobs:
- name: Run unit tests
run: |
cd ansible_collections
pip3 install -r ./skupper/network/tests/unit/requirements.txt
pip3 install -r ./skupper/skupper/tests/unit/requirements.txt
make unit-tests
5 changes: 2 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
*.tar.gz
skupper/network/docs/build
skupper/network/docs/temp-rst
skupper/network/tests/output
skupper/skupper/docs/
skupper/skupper/tests/output
__pycache__/
41 changes: 27 additions & 14 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,26 +1,28 @@
TARBALL := $(shell echo "skupper/network/skupper-network-`grep -E '^version:' skupper/network/galaxy.yml | awk '{print $$NF}'`.tar.gz")
TARBALL := $(shell echo "skupper/skupper/skupper-skupper-`grep -E '^version:' skupper/skupper/galaxy.yml | awk '{print $$NF}'`.tar.gz")

all: ansible-lint build
all: ansible-lint build-docs

dep:
pip install -r ./requirements.txt
pip install -r ./skupper/network/tests/unit/requirements.txt
pip install -r ./skupper/network/docs/requirements.txt
pip install -r ./skupper/skupper/tests/unit/requirements.txt
pip install -r ./skupper/skupper/docs/requirements.txt

ansible-lint:
cd skupper/network && ansible-lint --skip-list 'var-naming[pattern],var-naming[no-role-prefix]'
cd skupper/skupper && ansible-lint -v

release-changelog:
pip install --user -U antsibull-changelog
cd skupper/network && antsibull-changelog release
cd skupper/skupper && antsibull-changelog release

build-docs:
rm -rf skupper/network/docs/build skupper/network/docs/temp-rst
(cd skupper/network/docs && pip install --user -U -r requirements.txt && ./build.sh) && \
rm -rf ./docs && mv skupper/network/docs/build/html/ ./docs && touch ./docs/.nojekyll
build-docs: build install
rm -rf ./skupper/skupper/docs/*
antsibull-docs sphinx-init --use-current --dest-dir ./skupper/skupper/docs skupper.skupper
(cd skupper/skupper/docs && pip install --user -U -r requirements.txt && ./build.sh) && \
rm -rf ./docs && mv skupper/skupper/docs/build/html/ ./docs && touch ./docs/.nojekyll
rm -rf ./skupper/skupper/docs/*

build: clean build-docs
cd skupper/network && ansible-galaxy collection build
build: clean
cd skupper/skupper && ansible-galaxy collection build

clean:
@[[ -f "$(TARBALL)" ]] && rm $(TARBALL) || true
Expand All @@ -30,7 +32,18 @@ install:
@ansible-galaxy collection install -f "$(TARBALL)"

sanity-tests:
cd skupper/network && ansible-test sanity -v --color
cd skupper/skupper && ansible-test sanity -v --color

unit-tests:
cd skupper/network && ansible-test units -vvv --color
cd skupper/skupper && ansible-test units -vvv --color

e2e-setup:
cd examples/hello-world && ansible-playbook -i inventory.yml setup.yml

e2e-validate:
cd examples/hello-world && ansible-playbook -i inventory.yml test.yml

e2e-teardown:
cd examples/hello-world && ansible-playbook -i inventory.yml teardown.yml

e2e-test: e2e-setup e2e-validate e2e-teardown
23 changes: 13 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,20 +6,23 @@ Ansible collection and roles for skupper

## Collection name

skupperproject.skupper
skupper.skupper

## Roles

* [skupper](https://github.com/skupperproject/skupper-ansible/tree/main/skupper/network/roles/skupper)
* [skupper_cli_install](https://github.com/skupperproject/skupper-ansible/tree/main/skupper/network/roles/skupper_cli_install)
* [skupper_common (internal - should not be used directly)](https://github.com/skupperproject/skupper-ansible/tree/main/skupper/network/roles/skupper_common)
* [skupper_init](https://github.com/skupperproject/skupper-ansible/tree/main/skupper/network/roles/skupper_init)
* [skupper_delete](https://github.com/skupperproject/skupper-ansible/tree/main/skupper/network/roles/skupper_delete)
* [skupper_token](https://github.com/skupperproject/skupper-ansible/tree/main/skupper/network/roles/skupper_token)
* [skupper_link](https://github.com/skupperproject/skupper-ansible/tree/main/skupper/network/roles/skupper_link)
* [skupper_service](https://github.com/skupperproject/skupper-ansible/tree/main/skupper/network/roles/skupper_service)
* [skupper_update](https://github.com/skupperproject/skupper-ansible/tree/main/skupper/network/roles/skupper_update)
* [skupper_setup](https://github.com/skupperproject/skupper-ansible/tree/main/skupper/skupper/roles/skupper_setup)
* [skupper_cli_install](https://github.com/skupperproject/skupper-ansible/tree/main/skupper/skupper/roles/skupper_cli_install)
* [skupper_option (internal - should not be used directly)](https://github.com/skupperproject/skupper-ansible/tree/main/skupper/skupper/roles/skupper_option)
* [skupper_init](https://github.com/skupperproject/skupper-ansible/tree/main/skupper/skupper/roles/skupper_init)
* [skupper_teardown](https://github.com/skupperproject/skupper-ansible/tree/main/skupper/skupper/roles/skupper_teardown)
* [skupper_token](https://github.com/skupperproject/skupper-ansible/tree/main/skupper/skupper/roles/skupper_token)
* [skupper_link](https://github.com/skupperproject/skupper-ansible/tree/main/skupper/skupper/roles/skupper_link)
* [skupper_service](https://github.com/skupperproject/skupper-ansible/tree/main/skupper/skupper/roles/skupper_service)
* [skupper_update](https://github.com/skupperproject/skupper-ansible/tree/main/skupper/skupper/roles/skupper_update)

## Requirements

* python >= 3.9
* ansible >= 2.1
* kubectl binary on target hosts
* podman binary on target hosts
2 changes: 1 addition & 1 deletion docs/.buildinfo
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Sphinx build info version 1
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
config: 8e75efdab59539ee825b62b22b62bdf5
config: 01ba99357b9fe97b784fdfe65a6e108b
tags: 645f666f9bcd5a90fca523b33c5a78b7
15 changes: 8 additions & 7 deletions docs/collections/environment_variables.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<meta content="2.7.0" name="antsibull-docs" />

<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Index of all Collection Environment Variables &mdash; Skupper Ansible collection documentation</title>
<title>Index of all Collection Environment Variables &mdash; Ansible collections documentation</title>
<link rel="stylesheet" type="text/css" href="../_static/pygments.css?v=5707b69d" />
<link rel="stylesheet" type="text/css" href="../_static/css/ansible.css?v=c5b67dd2" />
<link rel="stylesheet" type="text/css" href="../_static/antsibull-minimal.css" />
Expand All @@ -24,7 +24,7 @@
<script src="../_static/sphinx_highlight.js?v=dc90522c"></script>
<script src="../_static/js/theme.js"></script>
<link rel="search" title="Search" href="../search.html" />
<link rel="prev" title="Index of all Modules" href="index_module.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
<link rel="prev" title="Index of all Roles" href="index_role.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->



Expand All @@ -46,7 +46,7 @@
<img class="DocSiteNav-logo"
src="../_static/images/Ansible-Mark-RGB_White.png"
alt="Ansible Logo">
<div class="DocSiteNav-title">Skupper Ansible Documentation</div>
<div class="DocSiteNav-title">Ansible Collections Documentation</div>
</a>
<div class="wy-grid-for-nav">
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
Expand All @@ -56,7 +56,7 @@


<a href="../index.html" class="icon icon-home">
Skupper Ansible collection
Ansible collections
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->

<div class="version">
Expand All @@ -81,6 +81,7 @@
<p class="caption" role="heading"><span class="caption-text">Plugin indexes:</span></p>
<ul>
<li class="toctree-l1"><a class="reference internal" href="index_module.html">Index of all Modules</a></li>
<li class="toctree-l1"><a class="reference internal" href="index_role.html">Index of all Roles</a></li>
</ul>
<p class="caption" role="heading"><span class="caption-text">Reference indexes:</span></p>
<ul class="current">
Expand All @@ -94,7 +95,7 @@

<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
<a href="../index.html">Skupper Ansible collection</a>
<a href="../index.html">Ansible collections</a>
</nav>

<div class="wy-nav-content">
Expand Down Expand Up @@ -126,13 +127,13 @@


<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
<a href="index_module.html" class="btn btn-neutral float-left" title="Index of all Modules" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
<a href="index_role.html" class="btn btn-neutral float-left" title="Index of all Roles" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
</div>

<hr/>

<div role="contentinfo">
<p>&#169; Copyright Skupper Ansible contributors.</p>
<p>&#169; Copyright Ansible contributors.</p>
</div>


Expand Down
13 changes: 7 additions & 6 deletions docs/collections/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<meta content="2.7.0" name="antsibull-docs" />

<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Collection Index &mdash; Skupper Ansible collection documentation</title>
<title>Collection Index &mdash; Ansible collections documentation</title>
<link rel="stylesheet" type="text/css" href="../_static/pygments.css?v=5707b69d" />
<link rel="stylesheet" type="text/css" href="../_static/css/ansible.css?v=c5b67dd2" />
<link rel="stylesheet" type="text/css" href="../_static/antsibull-minimal.css" />
Expand Down Expand Up @@ -47,7 +47,7 @@
<img class="DocSiteNav-logo"
src="../_static/images/Ansible-Mark-RGB_White.png"
alt="Ansible Logo">
<div class="DocSiteNav-title">Skupper Ansible Documentation</div>
<div class="DocSiteNav-title">Ansible Collections Documentation</div>
</a>
<div class="wy-grid-for-nav">
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
Expand All @@ -57,7 +57,7 @@


<a href="../index.html" class="icon icon-home">
Skupper Ansible collection
Ansible collections
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->

<div class="version">
Expand Down Expand Up @@ -85,6 +85,7 @@
<p class="caption" role="heading"><span class="caption-text">Plugin indexes:</span></p>
<ul>
<li class="toctree-l1"><a class="reference internal" href="index_module.html">Index of all Modules</a></li>
<li class="toctree-l1"><a class="reference internal" href="index_role.html">Index of all Roles</a></li>
</ul>
<p class="caption" role="heading"><span class="caption-text">Reference indexes:</span></p>
<ul>
Expand All @@ -98,7 +99,7 @@

<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
<a href="../index.html">Skupper Ansible collection</a>
<a href="../index.html">Ansible collections</a>
</nav>

<div class="wy-nav-content">
Expand All @@ -121,7 +122,7 @@
<span id="list-of-collections"></span><h1>Collection Index<a class="headerlink" href="#collection-index" title="Link to this heading"></a></h1>
<p>These are the collections documented here.</p>
<ul class="simple">
<li><p><a class="reference internal" href="skupper/network/index.html#plugins-in-skupper-network"><span class="std std-ref">skupper.network</span></a></p></li>
<li><p><a class="reference internal" href="skupper/skupper/index.html#plugins-in-skupper-skupper"><span class="std std-ref">skupper.skupper</span></a></p></li>
</ul>
<div class="toctree-wrapper compound">
</div>
Expand All @@ -140,7 +141,7 @@
<hr/>

<div role="contentinfo">
<p>&#169; Copyright Skupper Ansible contributors.</p>
<p>&#169; Copyright Ansible contributors.</p>
</div>


Expand Down
35 changes: 18 additions & 17 deletions docs/collections/index_module.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<meta content="2.7.0" name="antsibull-docs" />

<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Index of all Modules &mdash; Skupper Ansible collection documentation</title>
<title>Index of all Modules &mdash; Ansible collections documentation</title>
<link rel="stylesheet" type="text/css" href="../_static/pygments.css?v=5707b69d" />
<link rel="stylesheet" type="text/css" href="../_static/css/ansible.css?v=c5b67dd2" />
<link rel="stylesheet" type="text/css" href="../_static/antsibull-minimal.css" />
Expand All @@ -24,8 +24,8 @@
<script src="../_static/sphinx_highlight.js?v=dc90522c"></script>
<script src="../_static/js/theme.js"></script>
<link rel="search" title="Search" href="../search.html" />
<link rel="next" title="Index of all Collection Environment Variables" href="environment_variables.html" />
<link rel="prev" title="skupper.network.site_load moduleLoads site information as ansible facts into the respective host" href="skupper/network/site_load_module.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
<link rel="next" title="Index of all Roles" href="index_role.html" />
<link rel="prev" title="skupper.skupper.skupper_update roleUpdates a Skupper site" href="skupper/skupper/skupper_update_role.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->



Expand All @@ -47,7 +47,7 @@
<img class="DocSiteNav-logo"
src="../_static/images/Ansible-Mark-RGB_White.png"
alt="Ansible Logo">
<div class="DocSiteNav-title">Skupper Ansible Documentation</div>
<div class="DocSiteNav-title">Ansible Collections Documentation</div>
</a>
<div class="wy-grid-for-nav">
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
Expand All @@ -57,7 +57,7 @@


<a href="../index.html" class="icon icon-home">
Skupper Ansible collection
Ansible collections
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->

<div class="version">
Expand All @@ -82,9 +82,10 @@
<p class="caption" role="heading"><span class="caption-text">Plugin indexes:</span></p>
<ul class="current">
<li class="toctree-l1 current"><a class="current reference internal" href="#">Index of all Modules</a><ul>
<li class="toctree-l2"><a class="reference internal" href="#skupper-network">skupper.network</a></li>
<li class="toctree-l2"><a class="reference internal" href="#skupper-skupper">skupper.skupper</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="index_role.html">Index of all Roles</a></li>
</ul>
<p class="caption" role="heading"><span class="caption-text">Reference indexes:</span></p>
<ul>
Expand All @@ -98,7 +99,7 @@

<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
<a href="../index.html">Skupper Ansible collection</a>
<a href="../index.html">Ansible collections</a>
</nav>

<div class="wy-nav-content">
Expand All @@ -119,14 +120,14 @@

<section id="index-of-all-modules">
<span id="list-of-module-plugins"></span><h1>Index of all Modules<a class="headerlink" href="#index-of-all-modules" title="Link to this heading"></a></h1>
<section id="skupper-network">
<h2>skupper.network<a class="headerlink" href="#skupper-network" title="Link to this heading"></a></h2>
<section id="skupper-skupper">
<h2>skupper.skupper<a class="headerlink" href="#skupper-skupper" title="Link to this heading"></a></h2>
<ul class="simple">
<li><p><a class="reference internal" href="skupper/network/links_module.html#ansible-collections-skupper-network-links-module"><span class="std std-ref">skupper.network.links</span></a> – Update links based on provided links list</p></li>
<li><p><a class="reference internal" href="skupper/network/links_load_module.html#ansible-collections-skupper-network-links-load-module"><span class="std std-ref">skupper.network.links_load</span></a> – Loads existing links to other sites</p></li>
<li><p><a class="reference internal" href="skupper/network/services_module.html#ansible-collections-skupper-network-services-module"><span class="std std-ref">skupper.network.services</span></a> – Update services based on provided services list</p></li>
<li><p><a class="reference internal" href="skupper/network/services_load_module.html#ansible-collections-skupper-network-services-load-module"><span class="std std-ref">skupper.network.services_load</span></a> – Loads existing services and targets</p></li>
<li><p><a class="reference internal" href="skupper/network/site_load_module.html#ansible-collections-skupper-network-site-load-module"><span class="std std-ref">skupper.network.site_load</span></a> – Loads site information as ansible facts into the respective host</p></li>
<li><p><a class="reference internal" href="skupper/skupper/links_module.html#ansible-collections-skupper-skupper-links-module"><span class="std std-ref">skupper.skupper.links</span></a> – Update links based on provided links list</p></li>
<li><p><a class="reference internal" href="skupper/skupper/links_load_module.html#ansible-collections-skupper-skupper-links-load-module"><span class="std std-ref">skupper.skupper.links_load</span></a> – Loads existing links to other sites</p></li>
<li><p><a class="reference internal" href="skupper/skupper/services_module.html#ansible-collections-skupper-skupper-services-module"><span class="std std-ref">skupper.skupper.services</span></a> – Update services based on provided services list</p></li>
<li><p><a class="reference internal" href="skupper/skupper/services_load_module.html#ansible-collections-skupper-skupper-services-load-module"><span class="std std-ref">skupper.skupper.services_load</span></a> – Loads existing services and targets</p></li>
<li><p><a class="reference internal" href="skupper/skupper/site_load_module.html#ansible-collections-skupper-skupper-site-load-module"><span class="std std-ref">skupper.skupper.site_load</span></a> – Loads site information as ansible facts into the respective host</p></li>
</ul>
</section>
</section>
Expand All @@ -137,14 +138,14 @@ <h2>skupper.network<a class="headerlink" href="#skupper-network" title="Link to


<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
<a href="skupper/network/site_load_module.html" class="btn btn-neutral float-left" title="skupper.network.site_load moduleLoads site information as ansible facts into the respective host" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
<a href="environment_variables.html" class="btn btn-neutral float-right" title="Index of all Collection Environment Variables" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
<a href="skupper/skupper/skupper_update_role.html" class="btn btn-neutral float-left" title="skupper.skupper.skupper_update roleUpdates a Skupper site" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
<a href="index_role.html" class="btn btn-neutral float-right" title="Index of all Roles" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
</div>

<hr/>

<div role="contentinfo">
<p>&#169; Copyright Skupper Ansible contributors.</p>
<p>&#169; Copyright Ansible contributors.</p>
</div>


Expand Down
Loading

0 comments on commit 4cd639d

Please sign in to comment.