orchestrator-lso 2.3.0__tar.gz → 2.3.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {orchestrator_lso-2.3.0 → orchestrator_lso-2.3.1}/PKG-INFO +30 -45
- {orchestrator_lso-2.3.0 → orchestrator_lso-2.3.1}/README.md +21 -17
- {orchestrator_lso-2.3.0 → orchestrator_lso-2.3.1}/lso/__init__.py +2 -2
- {orchestrator_lso-2.3.0 → orchestrator_lso-2.3.1}/lso/app.py +1 -1
- {orchestrator_lso-2.3.0 → orchestrator_lso-2.3.1}/lso/config.py +1 -1
- {orchestrator_lso-2.3.0 → orchestrator_lso-2.3.1}/lso/environment.py +1 -1
- {orchestrator_lso-2.3.0 → orchestrator_lso-2.3.1}/lso/execute.py +13 -0
- {orchestrator_lso-2.3.0 → orchestrator_lso-2.3.1}/lso/playbook.py +1 -1
- {orchestrator_lso-2.3.0 → orchestrator_lso-2.3.1}/lso/routes/__init__.py +1 -1
- {orchestrator_lso-2.3.0 → orchestrator_lso-2.3.1}/lso/routes/default.py +1 -1
- {orchestrator_lso-2.3.0 → orchestrator_lso-2.3.1}/lso/routes/execute.py +13 -0
- {orchestrator_lso-2.3.0 → orchestrator_lso-2.3.1}/lso/routes/playbook.py +1 -1
- {orchestrator_lso-2.3.0 → orchestrator_lso-2.3.1}/lso/worker.py +1 -1
- {orchestrator_lso-2.3.0 → orchestrator_lso-2.3.1}/pyproject.toml +25 -24
- orchestrator_lso-2.3.0/.bumpversion.cfg +0 -16
- orchestrator_lso-2.3.0/.github/dependabot.yml +0 -11
- orchestrator_lso-2.3.0/.github/styles/config/vocabularies/Sphinx/accept.txt +0 -1
- orchestrator_lso-2.3.0/.github/styles/config/vocabularies/jargon/accept.txt +0 -10
- orchestrator_lso-2.3.0/.github/workflows/publish-package.yaml +0 -26
- orchestrator_lso-2.3.0/.github/workflows/run-linting-tests.yaml +0 -43
- orchestrator_lso-2.3.0/.github/workflows/run-unit-tests.yaml +0 -28
- orchestrator_lso-2.3.0/.github/workflows/sphinx.yaml +0 -43
- orchestrator_lso-2.3.0/.gitignore +0 -15
- orchestrator_lso-2.3.0/.vale.ini +0 -27
- orchestrator_lso-2.3.0/Dockerfile.example +0 -27
- orchestrator_lso-2.3.0/LICENSE +0 -202
- orchestrator_lso-2.3.0/docs/LSO_banner.jpg +0 -0
- orchestrator_lso-2.3.0/docs/Makefile +0 -20
- orchestrator_lso-2.3.0/docs/source/_static/custom.css +0 -13
- orchestrator_lso-2.3.0/docs/source/_static/lso_logo.png +0 -0
- orchestrator_lso-2.3.0/docs/source/conf.py +0 -79
- orchestrator_lso-2.3.0/docs/source/index.rst +0 -34
- orchestrator_lso-2.3.0/docs/source/module/config.rst +0 -6
- orchestrator_lso-2.3.0/docs/source/module/playbook.rst +0 -7
- orchestrator_lso-2.3.0/docs/source/module/routes/default.rst +0 -6
- orchestrator_lso-2.3.0/docs/source/module/routes/index.rst +0 -16
- orchestrator_lso-2.3.0/docs/source/module/routes/playbook.rst +0 -6
- orchestrator_lso-2.3.0/docs/source/modules.rst +0 -31
- orchestrator_lso-2.3.0/env.example +0 -21
- orchestrator_lso-2.3.0/test/__init__.py +0 -12
- orchestrator_lso-2.3.0/test/conftest.py +0 -79
- orchestrator_lso-2.3.0/test/routes/__init__.py +0 -12
- orchestrator_lso-2.3.0/test/routes/test_default.py +0 -33
- orchestrator_lso-2.3.0/test/routes/test_execute.py +0 -187
- orchestrator_lso-2.3.0/test/routes/test_playbook.py +0 -215
- orchestrator_lso-2.3.0/test/test-playbook.yaml +0 -9
- orchestrator_lso-2.3.0/test/test_execute.py +0 -126
- orchestrator_lso-2.3.0/test/test_playbook.py +0 -34
- orchestrator_lso-2.3.0/test/utils.py +0 -27
- {orchestrator_lso-2.3.0 → orchestrator_lso-2.3.1}/lso/schema.py +0 -0
- {orchestrator_lso-2.3.0 → orchestrator_lso-2.3.1}/lso/tasks.py +0 -0
- {orchestrator_lso-2.3.0 → orchestrator_lso-2.3.1}/lso/utils.py +0 -0
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: orchestrator-lso
|
|
3
|
-
Version: 2.3.
|
|
3
|
+
Version: 2.3.1
|
|
4
4
|
Summary: LSO, an API for remotely running Ansible playbooks.
|
|
5
|
+
Author: GÉANT Orchestration and Automation Team
|
|
5
6
|
Author-email: GÉANT Orchestration and Automation Team <goat@geant.org>
|
|
6
|
-
Requires-Python: >=3.11,<3.14
|
|
7
|
-
Description-Content-Type: text/markdown
|
|
8
7
|
License-Expression: Apache-2.0
|
|
9
8
|
Classifier: Intended Audience :: Information Technology
|
|
10
9
|
Classifier: Intended Audience :: System Administrators
|
|
@@ -25,38 +24,20 @@ Classifier: Intended Audience :: Telecommunications Industry
|
|
|
25
24
|
Classifier: Programming Language :: Python :: 3 :: Only
|
|
26
25
|
Classifier: Programming Language :: Python :: 3.11
|
|
27
26
|
Classifier: Programming Language :: Python :: 3.12
|
|
28
|
-
|
|
29
|
-
Requires-Dist: ansible-runner==2.4.1
|
|
27
|
+
Requires-Dist: ansible-runner==2.4.2
|
|
30
28
|
Requires-Dist: ansible==10.7.0
|
|
31
|
-
Requires-Dist: fastapi==0.
|
|
29
|
+
Requires-Dist: fastapi==0.120.4
|
|
32
30
|
Requires-Dist: httpx==0.28.1
|
|
33
|
-
Requires-Dist: uvicorn[standard]==0.
|
|
31
|
+
Requires-Dist: uvicorn[standard]==0.38.0
|
|
34
32
|
Requires-Dist: requests==2.32.5
|
|
35
|
-
Requires-Dist: pydantic-settings==2.
|
|
33
|
+
Requires-Dist: pydantic-settings==2.11.0
|
|
36
34
|
Requires-Dist: celery==5.5.3
|
|
37
35
|
Requires-Dist: redis==5.3.1
|
|
38
|
-
Requires-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
Requires-Dist: types-toml ; extra == "dev"
|
|
42
|
-
Requires-Dist: mypy_extensions ; extra == "dev"
|
|
43
|
-
Requires-Dist: pre-commit ; extra == "dev"
|
|
44
|
-
Requires-Dist: sphinx ; extra == "doc"
|
|
45
|
-
Requires-Dist: sphinx-rtd-theme ; extra == "doc"
|
|
46
|
-
Requires-Dist: docutils ; extra == "doc"
|
|
47
|
-
Requires-Dist: pytest ; extra == "test"
|
|
48
|
-
Requires-Dist: pytest-cov ; extra == "test"
|
|
49
|
-
Requires-Dist: Faker ; extra == "test"
|
|
50
|
-
Requires-Dist: responses ; extra == "test"
|
|
51
|
-
Requires-Dist: mypy ; extra == "test"
|
|
52
|
-
Requires-Dist: ruff ; extra == "test"
|
|
53
|
-
Requires-Dist: jsonschema ; extra == "test"
|
|
54
|
-
Requires-Dist: starlette ; extra == "test"
|
|
55
|
-
Project-URL: Documentation, https://workfloworchestrator.org/lso/
|
|
36
|
+
Requires-Python: >=3.11, <3.14
|
|
37
|
+
Project-URL: Documentation, https://docs.gap.geant.org
|
|
38
|
+
Project-URL: Homepage, https://workfloworchestrator.org/lso/
|
|
56
39
|
Project-URL: Source, https://github.com/workfloworchestrator/lso
|
|
57
|
-
|
|
58
|
-
Provides-Extra: doc
|
|
59
|
-
Provides-Extra: test
|
|
40
|
+
Description-Content-Type: text/markdown
|
|
60
41
|
|
|
61
42
|

|
|
62
43
|
[](https://pypi.org/project/orchestrator-lso)
|
|
@@ -65,10 +46,6 @@ Provides-Extra: test
|
|
|
65
46
|
|
|
66
47
|
LSO: an API that allows for remotely executing Ansible playbooks.
|
|
67
48
|
|
|
68
|
-
## Code documentation
|
|
69
|
-
|
|
70
|
-
Code documentation can be found at <https://workfloworchestrator.org/lso>
|
|
71
|
-
|
|
72
49
|
## Quick start
|
|
73
50
|
|
|
74
51
|
This is a quick setup guide for running on your local machine.
|
|
@@ -104,7 +81,6 @@ This will expose the API on port 8000. The container requires some more files to
|
|
|
104
81
|
|
|
105
82
|
### Install the module
|
|
106
83
|
|
|
107
|
-
|
|
108
84
|
As an alternative, below are a set of instructions for installing and running LSO directly on a machine.
|
|
109
85
|
|
|
110
86
|
*One of these should be what you're looking for:*
|
|
@@ -112,24 +88,18 @@ As an alternative, below are a set of instructions for installing and running LS
|
|
|
112
88
|
* Install the latest release
|
|
113
89
|
|
|
114
90
|
```bash
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
pip install orchestrator-lso
|
|
91
|
+
uv venv --python 3.12
|
|
92
|
+
uv add orchestrator-lso
|
|
119
93
|
```
|
|
120
94
|
|
|
121
95
|
* Install the source code
|
|
122
96
|
|
|
123
97
|
```bash
|
|
124
98
|
git clone https://github.com/workfloworchestrator/lso.git && cd lso
|
|
125
|
-
|
|
126
|
-
.
|
|
99
|
+
uv venv --python 3.12
|
|
100
|
+
. .venv/bin/activate
|
|
127
101
|
|
|
128
|
-
|
|
129
|
-
flit install --deps production
|
|
130
|
-
|
|
131
|
-
# Or, for the full development environment
|
|
132
|
-
flit install --deps develop
|
|
102
|
+
uv sync --all-extras --dev
|
|
133
103
|
```
|
|
134
104
|
|
|
135
105
|
### Running the app
|
|
@@ -161,3 +131,18 @@ celery -A lso.worker worker --loglevel=info -Q lso-worker-queue
|
|
|
161
131
|
2. ThreadPoolExecutor (Local Execution)
|
|
162
132
|
|
|
163
133
|
For local concurrent tasks, set `EXECUTOR=threadpool` and configure `MAX_THREAD_POOL_WORKERS`.
|
|
134
|
+
|
|
135
|
+
## Contributing
|
|
136
|
+
|
|
137
|
+
We use [uv](https://docs.astral.sh/uv/getting-started/installation/) to manage dependencies.
|
|
138
|
+
|
|
139
|
+
To get started, run:
|
|
140
|
+
|
|
141
|
+
```
|
|
142
|
+
uv sync --all-extras --dev
|
|
143
|
+
pre-commit install
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
## Code documentation
|
|
147
|
+
|
|
148
|
+
Code documentation can be found at <https://workfloworchestrator.org/lso>
|
|
@@ -5,10 +5,6 @@
|
|
|
5
5
|
|
|
6
6
|
LSO: an API that allows for remotely executing Ansible playbooks.
|
|
7
7
|
|
|
8
|
-
## Code documentation
|
|
9
|
-
|
|
10
|
-
Code documentation can be found at <https://workfloworchestrator.org/lso>
|
|
11
|
-
|
|
12
8
|
## Quick start
|
|
13
9
|
|
|
14
10
|
This is a quick setup guide for running on your local machine.
|
|
@@ -44,7 +40,6 @@ This will expose the API on port 8000. The container requires some more files to
|
|
|
44
40
|
|
|
45
41
|
### Install the module
|
|
46
42
|
|
|
47
|
-
|
|
48
43
|
As an alternative, below are a set of instructions for installing and running LSO directly on a machine.
|
|
49
44
|
|
|
50
45
|
*One of these should be what you're looking for:*
|
|
@@ -52,24 +47,18 @@ As an alternative, below are a set of instructions for installing and running LS
|
|
|
52
47
|
* Install the latest release
|
|
53
48
|
|
|
54
49
|
```bash
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
pip install orchestrator-lso
|
|
50
|
+
uv venv --python 3.12
|
|
51
|
+
uv add orchestrator-lso
|
|
59
52
|
```
|
|
60
53
|
|
|
61
54
|
* Install the source code
|
|
62
55
|
|
|
63
56
|
```bash
|
|
64
57
|
git clone https://github.com/workfloworchestrator/lso.git && cd lso
|
|
65
|
-
|
|
66
|
-
.
|
|
67
|
-
|
|
68
|
-
pip install flit
|
|
69
|
-
flit install --deps production
|
|
58
|
+
uv venv --python 3.12
|
|
59
|
+
. .venv/bin/activate
|
|
70
60
|
|
|
71
|
-
|
|
72
|
-
flit install --deps develop
|
|
61
|
+
uv sync --all-extras --dev
|
|
73
62
|
```
|
|
74
63
|
|
|
75
64
|
### Running the app
|
|
@@ -100,4 +89,19 @@ celery -A lso.worker worker --loglevel=info -Q lso-worker-queue
|
|
|
100
89
|
```
|
|
101
90
|
2. ThreadPoolExecutor (Local Execution)
|
|
102
91
|
|
|
103
|
-
For local concurrent tasks, set `EXECUTOR=threadpool` and configure `MAX_THREAD_POOL_WORKERS`.
|
|
92
|
+
For local concurrent tasks, set `EXECUTOR=threadpool` and configure `MAX_THREAD_POOL_WORKERS`.
|
|
93
|
+
|
|
94
|
+
## Contributing
|
|
95
|
+
|
|
96
|
+
We use [uv](https://docs.astral.sh/uv/getting-started/installation/) to manage dependencies.
|
|
97
|
+
|
|
98
|
+
To get started, run:
|
|
99
|
+
|
|
100
|
+
```
|
|
101
|
+
uv sync --all-extras --dev
|
|
102
|
+
pre-commit install
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
## Code documentation
|
|
106
|
+
|
|
107
|
+
Code documentation can be found at <https://workfloworchestrator.org/lso>
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Copyright 2023-
|
|
1
|
+
# Copyright 2023-2025 GÉANT Vereniging.
|
|
2
2
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
3
|
# you may not use this file except in compliance with the License.
|
|
4
4
|
# You may obtain a copy of the License at
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
|
|
14
14
|
"""LSO, an API for remotely running Ansible playbooks."""
|
|
15
15
|
|
|
16
|
-
__version__ = "2.3.
|
|
16
|
+
__version__ = "2.3.1"
|
|
17
17
|
|
|
18
18
|
import logging
|
|
19
19
|
|
|
@@ -1,3 +1,16 @@
|
|
|
1
|
+
# Copyright 2023-2025 GÉANT Vereniging.
|
|
2
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
|
+
# you may not use this file except in compliance with the License.
|
|
4
|
+
# You may obtain a copy of the License at
|
|
5
|
+
#
|
|
6
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
|
7
|
+
#
|
|
8
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
9
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
10
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
|
+
# See the License for the specific language governing permissions and
|
|
12
|
+
# limitations under the License.
|
|
13
|
+
|
|
1
14
|
"""Module for handling the execution of arbitrary executables."""
|
|
2
15
|
|
|
3
16
|
import subprocess # noqa: S404
|
|
@@ -1,3 +1,16 @@
|
|
|
1
|
+
# Copyright 2023-2025 GÉANT Vereniging.
|
|
2
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
|
+
# you may not use this file except in compliance with the License.
|
|
4
|
+
# You may obtain a copy of the License at
|
|
5
|
+
#
|
|
6
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
|
7
|
+
#
|
|
8
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
9
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
10
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
|
+
# See the License for the specific language governing permissions and
|
|
12
|
+
# limitations under the License.
|
|
13
|
+
|
|
1
14
|
"""FastAPI route for running arbitrary executables."""
|
|
2
15
|
|
|
3
16
|
import asyncio
|
|
@@ -1,10 +1,6 @@
|
|
|
1
|
-
[build-system]
|
|
2
|
-
build-backend = "flit_core.buildapi"
|
|
3
|
-
requires = ["flit_core >=3.2,<4"]
|
|
4
|
-
|
|
5
1
|
[project]
|
|
6
2
|
name = "orchestrator-lso"
|
|
7
|
-
|
|
3
|
+
version = "2.3.1"
|
|
8
4
|
description = "LSO, an API for remotely running Ansible playbooks."
|
|
9
5
|
readme = "README.md"
|
|
10
6
|
license = "Apache-2.0"
|
|
@@ -34,23 +30,25 @@ classifiers = [
|
|
|
34
30
|
"Programming Language :: Python :: 3.12",
|
|
35
31
|
]
|
|
36
32
|
dependencies = [
|
|
37
|
-
"ansible-runner==2.4.
|
|
33
|
+
"ansible-runner==2.4.2",
|
|
38
34
|
"ansible==10.7.0",
|
|
39
|
-
"fastapi==0.
|
|
35
|
+
"fastapi==0.120.4",
|
|
40
36
|
"httpx==0.28.1",
|
|
41
|
-
"uvicorn[standard]==0.
|
|
37
|
+
"uvicorn[standard]==0.38.0",
|
|
42
38
|
"requests==2.32.5",
|
|
43
|
-
"pydantic-settings==2.
|
|
39
|
+
"pydantic-settings==2.11.0",
|
|
44
40
|
"celery==5.5.3",
|
|
45
41
|
"redis==5.3.1",
|
|
46
42
|
]
|
|
47
43
|
|
|
48
44
|
[project.urls]
|
|
49
|
-
|
|
45
|
+
Homepage = "https://workfloworchestrator.org/lso/"
|
|
46
|
+
Documentation = "https://docs.gap.geant.org"
|
|
50
47
|
Source = "https://github.com/workfloworchestrator/lso"
|
|
51
48
|
|
|
52
|
-
[
|
|
53
|
-
|
|
49
|
+
[dependency-groups]
|
|
50
|
+
dev = [
|
|
51
|
+
"bumpversion",
|
|
54
52
|
"pytest",
|
|
55
53
|
"pytest-cov",
|
|
56
54
|
"Faker",
|
|
@@ -59,6 +57,12 @@ test = [
|
|
|
59
57
|
"ruff",
|
|
60
58
|
"jsonschema",
|
|
61
59
|
"starlette",
|
|
60
|
+
"types-setuptools",
|
|
61
|
+
"types-requests",
|
|
62
|
+
"toml",
|
|
63
|
+
"types-toml",
|
|
64
|
+
"mypy_extensions",
|
|
65
|
+
"pre-commit>=4.3.0",
|
|
62
66
|
]
|
|
63
67
|
|
|
64
68
|
doc = [
|
|
@@ -67,15 +71,16 @@ doc = [
|
|
|
67
71
|
"docutils",
|
|
68
72
|
]
|
|
69
73
|
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
"pre-commit",
|
|
77
|
-
]
|
|
74
|
+
[build-system]
|
|
75
|
+
build-backend = "uv_build"
|
|
76
|
+
requires = ["uv_build >=0.9.3,<0.10.0"]
|
|
77
|
+
|
|
78
|
+
[tool.uv]
|
|
79
|
+
prerelease = "if-necessary"
|
|
78
80
|
|
|
81
|
+
[tool.uv.build-backend]
|
|
82
|
+
module-name = "lso"
|
|
83
|
+
module-root = ""
|
|
79
84
|
|
|
80
85
|
[tool.mypy]
|
|
81
86
|
exclude = [
|
|
@@ -181,7 +186,3 @@ ban-relative-imports = "all"
|
|
|
181
186
|
[tool.ruff.lint.isort]
|
|
182
187
|
known-third-party = []
|
|
183
188
|
known-first-party = ["test", "docs"]
|
|
184
|
-
|
|
185
|
-
[tool.flit.module]
|
|
186
|
-
name = "lso"
|
|
187
|
-
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
[bumpversion]
|
|
2
|
-
current_version = 2.3.0
|
|
3
|
-
commit = False
|
|
4
|
-
tag = False
|
|
5
|
-
parse = (?P<major>\d+)\.(?P<minor>\d+)\.(?P<patch>\d+)(rc(?P<build>\d+))?
|
|
6
|
-
serialize =
|
|
7
|
-
{major}.{minor}.{patch}rc{build}
|
|
8
|
-
{major}.{minor}.{patch}
|
|
9
|
-
|
|
10
|
-
[bumpversion:file:lso/__init__.py]
|
|
11
|
-
search = __version__ = "{current_version}"
|
|
12
|
-
replace = __version__ = "{new_version}"
|
|
13
|
-
|
|
14
|
-
[bumpversion:file:Dockerfile.example]
|
|
15
|
-
search = RUN pip install orchestrator-lso=="{current_version}"
|
|
16
|
-
replace = RUN pip install orchestrator-lso=="{new_version}"
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
# To get started with Dependabot version updates, you'll need to specify which
|
|
2
|
-
# package ecosystems to update and where the package manifests are located.
|
|
3
|
-
# Please see the documentation for all configuration options:
|
|
4
|
-
# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates
|
|
5
|
-
|
|
6
|
-
version: 2
|
|
7
|
-
updates:
|
|
8
|
-
- package-ecosystem: "pip" # See documentation for possible values
|
|
9
|
-
directory: "/" # Location of package manifests
|
|
10
|
-
schedule:
|
|
11
|
-
interval: "weekly"
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
param
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
name: Publish package on PyPI
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
release:
|
|
5
|
-
types: [created]
|
|
6
|
-
|
|
7
|
-
jobs:
|
|
8
|
-
deploy:
|
|
9
|
-
runs-on: ubuntu-latest
|
|
10
|
-
steps:
|
|
11
|
-
- uses: actions/checkout@v4
|
|
12
|
-
- name: Set up Python
|
|
13
|
-
uses: actions/setup-python@v5
|
|
14
|
-
with:
|
|
15
|
-
python-version: '3.x'
|
|
16
|
-
- name: Install dependencies
|
|
17
|
-
run: |
|
|
18
|
-
python -m pip install --upgrade pip
|
|
19
|
-
pip install flit
|
|
20
|
-
env:
|
|
21
|
-
FLIT_ROOT_INSTALL: 1
|
|
22
|
-
- name: Build and publish
|
|
23
|
-
env:
|
|
24
|
-
FLIT_USERNAME: ${{ secrets.FLIT_USERNAME }}
|
|
25
|
-
FLIT_PASSWORD: ${{ secrets.FLIT_PASSWORD }}
|
|
26
|
-
run: flit publish
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
# This workflow will install Python dependencies, run tests and lint with a variety of Python versions
|
|
2
|
-
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
|
|
3
|
-
|
|
4
|
-
name: Linting tests
|
|
5
|
-
|
|
6
|
-
on:
|
|
7
|
-
push:
|
|
8
|
-
pull_request:
|
|
9
|
-
branches: [main]
|
|
10
|
-
workflow_call:
|
|
11
|
-
|
|
12
|
-
jobs:
|
|
13
|
-
build:
|
|
14
|
-
name: Linting Tests
|
|
15
|
-
runs-on: ubuntu-latest
|
|
16
|
-
strategy:
|
|
17
|
-
matrix:
|
|
18
|
-
python-version: ['3.11', '3.12']
|
|
19
|
-
fail-fast: false
|
|
20
|
-
|
|
21
|
-
steps:
|
|
22
|
-
- uses: actions/checkout@v4
|
|
23
|
-
- name: Set up Python ${{ matrix.python-version }}
|
|
24
|
-
uses: actions/setup-python@v5
|
|
25
|
-
with:
|
|
26
|
-
python-version: ${{ matrix.python-version }}
|
|
27
|
-
- name: Install dependencies
|
|
28
|
-
run: |
|
|
29
|
-
python -m pip install --upgrade pip
|
|
30
|
-
pip install flit
|
|
31
|
-
flit install --deps develop --symlink
|
|
32
|
-
env:
|
|
33
|
-
FLIT_ROOT_INSTALL: 1
|
|
34
|
-
- name: Check formatting with ruff
|
|
35
|
-
run: |
|
|
36
|
-
ruff format --respect-gitignore --preview --check .
|
|
37
|
-
- name: Lint with ruff
|
|
38
|
-
run: |
|
|
39
|
-
# stop the build if there are Python syntax errors or undefined names
|
|
40
|
-
ruff check --respect-gitignore --preview .
|
|
41
|
-
- name: Check with mypy
|
|
42
|
-
run: |
|
|
43
|
-
mypy .
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
name: Unit tests
|
|
2
|
-
on:
|
|
3
|
-
push:
|
|
4
|
-
workflow_call:
|
|
5
|
-
|
|
6
|
-
jobs:
|
|
7
|
-
container_job:
|
|
8
|
-
name: Unit tests
|
|
9
|
-
runs-on: ubuntu-latest
|
|
10
|
-
strategy:
|
|
11
|
-
matrix:
|
|
12
|
-
python-version: ['3.11', '3.12']
|
|
13
|
-
fail-fast: false
|
|
14
|
-
container: python:${{ matrix.python-version }}-slim
|
|
15
|
-
steps:
|
|
16
|
-
# Downloads a copy of the code in your repository before running CI tests
|
|
17
|
-
- name: Check out repository code
|
|
18
|
-
uses: actions/checkout@v4
|
|
19
|
-
|
|
20
|
-
- name: Install dependencies
|
|
21
|
-
run: |
|
|
22
|
-
python -m pip install --upgrade pip
|
|
23
|
-
pip install flit
|
|
24
|
-
flit install --deps develop --symlink
|
|
25
|
-
env:
|
|
26
|
-
FLIT_ROOT_INSTALL: 1
|
|
27
|
-
- name: Run Unit tests
|
|
28
|
-
run: pytest --cov-branch --cov=lso --cov-report=xml
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
name: "Sphinx: render docs"
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
push:
|
|
5
|
-
branches:
|
|
6
|
-
- main
|
|
7
|
-
|
|
8
|
-
jobs:
|
|
9
|
-
docs:
|
|
10
|
-
runs-on: ubuntu-latest
|
|
11
|
-
permissions:
|
|
12
|
-
contents: write
|
|
13
|
-
steps:
|
|
14
|
-
- uses: actions/checkout@v4
|
|
15
|
-
- name: Set up Python environment
|
|
16
|
-
uses: actions/setup-python@v5
|
|
17
|
-
with:
|
|
18
|
-
python-version: 3.12
|
|
19
|
-
- name: Install requirements
|
|
20
|
-
run: |
|
|
21
|
-
python -m pip install --upgrade pip
|
|
22
|
-
pip install flit
|
|
23
|
-
flit install --deps develop --symlink
|
|
24
|
-
env:
|
|
25
|
-
FLIT_ROOT_INSTALL: 1
|
|
26
|
-
- name: Build documentation
|
|
27
|
-
run: TZ=UTC sphinx-build -b html docs/source docs/build
|
|
28
|
-
- uses: ruby/setup-ruby@v1
|
|
29
|
-
with:
|
|
30
|
-
ruby-version: '3.3'
|
|
31
|
-
- uses: errata-ai/vale-action@reviewdog
|
|
32
|
-
with:
|
|
33
|
-
files: "docs/source/,lso/"
|
|
34
|
-
separator: ','
|
|
35
|
-
fail_on_error: true
|
|
36
|
-
vale_flags: "--glob=*.{rst,py}"
|
|
37
|
-
- uses: peaceiris/actions-gh-pages@v3
|
|
38
|
-
if: ${{ !env.ACT }}
|
|
39
|
-
with:
|
|
40
|
-
publish_branch: gh-pages
|
|
41
|
-
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
42
|
-
publish_dir: docs/build/
|
|
43
|
-
enable_jekyll: false
|
orchestrator_lso-2.3.0/.vale.ini
DELETED
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
StylesPath = .github/styles
|
|
2
|
-
|
|
3
|
-
MinAlertLevel = suggestion
|
|
4
|
-
|
|
5
|
-
Vocab = jargon, Sphinx
|
|
6
|
-
|
|
7
|
-
Packages = proselint, Microsoft
|
|
8
|
-
|
|
9
|
-
[*]
|
|
10
|
-
BasedOnStyles = Vale, proselint, Microsoft
|
|
11
|
-
; Found to be too intrusive
|
|
12
|
-
Microsoft.Passive = NO
|
|
13
|
-
; We are not a general audience
|
|
14
|
-
Microsoft.GeneralURL = NO
|
|
15
|
-
; It's okay to leave TODOs in the code, that's what they're for
|
|
16
|
-
proselint.Annotations = NO
|
|
17
|
-
; Replacing a ... with … shouldn't be holding back the entire CI pipeline
|
|
18
|
-
proselint.Typography = warning
|
|
19
|
-
; Same applies for not using contractions
|
|
20
|
-
Microsoft.Contractions = warning
|
|
21
|
-
Microsoft.Headings = NO
|
|
22
|
-
Microsoft.SentenceLength = NO
|
|
23
|
-
|
|
24
|
-
TokenIgnores = (:class:`\S+`),(:returns?.*:),(:param.+:),(noqa.*)
|
|
25
|
-
|
|
26
|
-
[formats]
|
|
27
|
-
py = rst
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
FROM python:3.12-alpine
|
|
2
|
-
|
|
3
|
-
WORKDIR /app
|
|
4
|
-
|
|
5
|
-
# Copy in requirements files, if needed
|
|
6
|
-
# These could be for Ansible Galaxy, Poetry, or a requirements.txt file
|
|
7
|
-
COPY ./requirements.txt ./requirements.txt
|
|
8
|
-
COPY ./ansible-galaxy-requirements.yaml ./ansible-galaxy-requirements.yaml
|
|
9
|
-
|
|
10
|
-
# Install required system packages
|
|
11
|
-
RUN apk add --update --no-cache gcc libc-dev libffi-dev openssh
|
|
12
|
-
|
|
13
|
-
# Install the LSO python package, and additional requirements
|
|
14
|
-
RUN pip install orchestrator-lso=="2.3.0"
|
|
15
|
-
RUN pip install -r requirements.txt
|
|
16
|
-
|
|
17
|
-
# Install required Ansible Galaxy roles and collections
|
|
18
|
-
RUN ansible-galaxy install \
|
|
19
|
-
-r ansible-galaxy-requirements.yaml \
|
|
20
|
-
-p /app/gap/ansible
|
|
21
|
-
RUN ansible-galaxy collection install \
|
|
22
|
-
-r ansible-galaxy-requirements.yaml \
|
|
23
|
-
-p /app/gap/ansible
|
|
24
|
-
|
|
25
|
-
EXPOSE 8000
|
|
26
|
-
ENTRYPOINT []
|
|
27
|
-
CMD ["python", "-m", "uvicorn", "lso.app:app", "--host", "0.0.0.0", "--port", "8000"]
|