edge-containers-cli 4.1.1__tar.gz → 4.2.0__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.
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.copier-answers.yml +1 -1
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.github/workflows/ci.yml +0 -8
- edge_containers_cli-4.2.0/Dockerfile +13 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/PKG-INFO +1 -2
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/README.md +0 -1
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/_version.py +2 -2
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/cli.py +6 -6
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/cmds/argo_commands.py +8 -8
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/cmds/commands.py +3 -3
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/cmds/demo_commands.py +2 -2
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/cmds/k8s_commands.py +4 -4
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli.egg-info/PKG-INFO +1 -2
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli.egg-info/SOURCES.txt +0 -1
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/data/argocd.yaml +4 -4
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/test_argocd.py +12 -12
- edge_containers_cli-4.1.1/.github/workflows/_container.yml +0 -60
- edge_containers_cli-4.1.1/Dockerfile +0 -31
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.devcontainer/devcontainer.json +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.github/CONTRIBUTING.md +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.github/ISSUE_TEMPLATE/bug_report.md +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.github/ISSUE_TEMPLATE/issue.md +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.github/PULL_REQUEST_TEMPLATE/pull_request_template.md +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.github/actions/install_requirements/action.yml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.github/dependabot.yml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.github/pages/index.html +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.github/pages/make_switcher.py +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.github/workflows/_check.yml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.github/workflows/_dist.yml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.github/workflows/_pypi.yml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.github/workflows/_release.yml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.github/workflows/_test.yml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.github/workflows/_tox.yml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.gitignore +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.pre-commit-config.yaml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.vscode/extensions.json +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.vscode/launch.json +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.vscode/settings.json +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.vscode/tasks.json +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/LICENSE +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/conf.py +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/explanations/decisions/0001-record-architecture-decisions.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/explanations/decisions/0002-switched-to-pip-skeleton.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/explanations/decisions.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/how-to/build-docs.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/how-to/contribute.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/how-to/lint.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/how-to/make-release.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/how-to/pin-requirements.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/how-to/run-tests.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/how-to/static-analysis.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/how-to/test-container.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/how-to/update-tools.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/index.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/reference/standards.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/tutorials/dev-install.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/genindex.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/images/dls-favicon.ico +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/images/dls-logo.svg +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/index.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/user/explanations/docs-structure.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/user/how-to/run-container.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/user/index.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/user/reference/api.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/user/tutorials/installation.rst +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/pyproject.toml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/setup.cfg +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/__init__.py +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/__main__.py +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/autocomplete.py +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/backend.py +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/cmds/__init__.py +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/cmds/helm.py +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/cmds/monitor.py +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/cmds/monitor.tcss +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/definitions.py +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/git.py +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/globals.py +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/logging.py +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/shell.py +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/utils.py +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli.egg-info/dependency_links.txt +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli.egg-info/entry_points.txt +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli.egg-info/requires.txt +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli.egg-info/top_level.txt +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/__init__.py +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/conftest.py +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/data/bl01t-deployment/apps/values.yaml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/data/bl01t-services/services/bl01t-ea-test-01/Chart.yaml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/data/bl01t-services/services/bl01t-ea-test-01/config/ioc.db +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/data/bl01t-services/services/bl01t-ea-test-01/config/ioc.yaml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/data/bl01t-services/services/bl01t-ea-test-01/templates/configmap.yaml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/data/bl01t-services/services/bl01t-ea-test-01/values.yaml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/data/bl01t-services/services/bl01t-ea-test-02/Chart.yaml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/data/bl01t-services/services/bl01t-ea-test-02/values.yaml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/data/bl01t-services/services/dls-aravis/Chart.yaml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/data/bl01t-services/services/dls-aravis/config/ioc.yaml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/data/bl01t-services/services/dls-aravis/templates/configmap.yaml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/data/bl01t-services/services/dls-aravis/values.yaml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/data/bl01t-services/services/values.yaml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/data/cli.yaml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/data/k8s.yaml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/data/yaml.yaml +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/test_cli.py +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/test_demo.py +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/test_k8s.py +0 -0
- {edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/test_unit.py +0 -0
|
@@ -5,7 +5,7 @@ author_email: giles.knap@gmail.com
|
|
|
5
5
|
author_name: Giles Knap
|
|
6
6
|
description: CLI for deploying and managing epics containers IOCs and services
|
|
7
7
|
distribution_name: edge-containers-cli
|
|
8
|
-
docker:
|
|
8
|
+
docker: false
|
|
9
9
|
docs_type: README
|
|
10
10
|
git_platform: github.com
|
|
11
11
|
github_org: epics-containers
|
|
@@ -34,14 +34,6 @@ jobs:
|
|
|
34
34
|
secrets:
|
|
35
35
|
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
|
|
36
36
|
|
|
37
|
-
container:
|
|
38
|
-
needs: check
|
|
39
|
-
if: needs.check.outputs.branch-pr == ''
|
|
40
|
-
uses: ./.github/workflows/_container.yml
|
|
41
|
-
permissions:
|
|
42
|
-
contents: read
|
|
43
|
-
packages: write
|
|
44
|
-
|
|
45
37
|
dist:
|
|
46
38
|
needs: check
|
|
47
39
|
if: needs.check.outputs.branch-pr == ''
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
# The devcontainer should use the developer target and run as root with podman
|
|
2
|
+
# or docker with user namespaces.
|
|
3
|
+
ARG PYTHON_VERSION=3.11
|
|
4
|
+
FROM python:${PYTHON_VERSION} as developer
|
|
5
|
+
|
|
6
|
+
# Add any system dependencies for the developer/build environment here
|
|
7
|
+
RUN apt-get update && apt-get install -y --no-install-recommends \
|
|
8
|
+
graphviz \
|
|
9
|
+
&& rm -rf /var/lib/apt/lists/*
|
|
10
|
+
|
|
11
|
+
# Set up a virtual environment and put it in PATH
|
|
12
|
+
RUN python -m venv /venv
|
|
13
|
+
ENV PATH=/venv/bin:$PATH
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: edge-containers-cli
|
|
3
|
-
Version: 4.
|
|
3
|
+
Version: 4.2.0
|
|
4
4
|
Summary: CLI for deploying and managing epics containers IOCs and services
|
|
5
5
|
Author-email: Giles Knap <giles.knap@gmail.com>
|
|
6
6
|
License: Apache License
|
|
@@ -250,7 +250,6 @@ https://epics-containers.github.io/
|
|
|
250
250
|
Source | <https://github.com/epics-containers/edge-containers-cli>
|
|
251
251
|
:---: | :---:
|
|
252
252
|
PyPI | `pip install edge-containers-cli`
|
|
253
|
-
Docker | `docker run ghcr.io/epics-containers/edge-containers-cli:latest`
|
|
254
253
|
Releases | <https://github.com/epics-containers/edge-containers-cli/releases>
|
|
255
254
|
|
|
256
255
|
|
|
@@ -15,7 +15,6 @@ https://epics-containers.github.io/
|
|
|
15
15
|
Source | <https://github.com/epics-containers/edge-containers-cli>
|
|
16
16
|
:---: | :---:
|
|
17
17
|
PyPI | `pip install edge-containers-cli`
|
|
18
|
-
Docker | `docker run ghcr.io/epics-containers/edge-containers-cli:latest`
|
|
19
18
|
Releases | <https://github.com/epics-containers/edge-containers-cli/releases>
|
|
20
19
|
|
|
21
20
|
|
|
@@ -234,13 +234,13 @@ def start(
|
|
|
234
234
|
service_name: str = typer.Argument(
|
|
235
235
|
..., help="Name of the service container to start", autocompletion=all_svc
|
|
236
236
|
),
|
|
237
|
-
|
|
237
|
+
commit: bool = typer.Option(False, help="Commits the values to the git repo"),
|
|
238
238
|
):
|
|
239
239
|
"""Start a service"""
|
|
240
240
|
try:
|
|
241
|
-
backend.commands.start(service_name,
|
|
241
|
+
backend.commands.start(service_name, commit)
|
|
242
242
|
except GitError as e:
|
|
243
|
-
msg = f"{str(e)} - Try 'ec start <service> --
|
|
243
|
+
msg = f"{str(e)} - Commit failed. Try 'ec start <service> --no-commit to set values without updating git"
|
|
244
244
|
raise GitError(msg) from e
|
|
245
245
|
|
|
246
246
|
|
|
@@ -251,13 +251,13 @@ def stop(
|
|
|
251
251
|
help="Name of the service container to stop",
|
|
252
252
|
autocompletion=running_svc,
|
|
253
253
|
),
|
|
254
|
-
|
|
254
|
+
commit: bool = typer.Option(False, help="Commits the values to the git repo"),
|
|
255
255
|
):
|
|
256
256
|
"""Stop a service"""
|
|
257
257
|
try:
|
|
258
|
-
backend.commands.stop(service_name,
|
|
258
|
+
backend.commands.stop(service_name, commit)
|
|
259
259
|
except GitError as e:
|
|
260
|
-
msg = f"{str(e)} - Try ec stop <service> --
|
|
260
|
+
msg = f"{str(e)} - Commit failed. Try ec stop <service> --no-commit to set values without updating git"
|
|
261
261
|
raise GitError(msg) from e
|
|
262
262
|
|
|
263
263
|
|
|
@@ -84,19 +84,19 @@ class ArgoCommands(Commands):
|
|
|
84
84
|
)
|
|
85
85
|
shell.run_command(cmd, skip_on_dryrun=True)
|
|
86
86
|
|
|
87
|
-
def start(self, service_name,
|
|
87
|
+
def start(self, service_name, commit):
|
|
88
88
|
self._check_service(service_name)
|
|
89
|
-
if
|
|
90
|
-
patch_value(self.target, f"ec_services.{service_name}.enabled", True)
|
|
91
|
-
else:
|
|
89
|
+
if commit:
|
|
92
90
|
push_value(self.target, f"ec_services.{service_name}.enabled", True)
|
|
91
|
+
else:
|
|
92
|
+
patch_value(self.target, f"ec_services.{service_name}.enabled", True)
|
|
93
93
|
|
|
94
|
-
def stop(self, service_name,
|
|
94
|
+
def stop(self, service_name, commit):
|
|
95
95
|
self._check_service(service_name)
|
|
96
|
-
if
|
|
97
|
-
patch_value(self.target, f"ec_services.{service_name}.enabled", False)
|
|
98
|
-
else:
|
|
96
|
+
if commit:
|
|
99
97
|
push_value(self.target, f"ec_services.{service_name}.enabled", False)
|
|
98
|
+
else:
|
|
99
|
+
patch_value(self.target, f"ec_services.{service_name}.enabled", False)
|
|
100
100
|
|
|
101
101
|
def _get_logs(self, service_name, prev) -> str:
|
|
102
102
|
namespace, app = extract_ns_app(self.target)
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/cmds/commands.py
RENAMED
|
@@ -39,7 +39,7 @@ class Commands(ABC):
|
|
|
39
39
|
Methods not exposed to the CLI should be private
|
|
40
40
|
"""
|
|
41
41
|
|
|
42
|
-
params_opt_out: dict[str, list[str]] = {}
|
|
42
|
+
params_opt_out: dict[str, list[str]] = {} # Optionally drop parameters from the CLI
|
|
43
43
|
|
|
44
44
|
def __init__(self, ctx: ECContext):
|
|
45
45
|
self._target = ctx.target
|
|
@@ -103,11 +103,11 @@ class Commands(ABC):
|
|
|
103
103
|
raise NotImplementedError
|
|
104
104
|
|
|
105
105
|
@abstractmethod
|
|
106
|
-
def start(self, service_name: str,
|
|
106
|
+
def start(self, service_name: str, commit: bool) -> None:
|
|
107
107
|
raise NotImplementedError
|
|
108
108
|
|
|
109
109
|
@abstractmethod
|
|
110
|
-
def stop(self, service_name: str,
|
|
110
|
+
def stop(self, service_name: str, commit: bool) -> None:
|
|
111
111
|
raise NotImplementedError
|
|
112
112
|
|
|
113
113
|
def template(self, svc_instance: Path, args: str) -> None:
|
|
@@ -87,7 +87,7 @@ class DemoCommands(Commands):
|
|
|
87
87
|
self.start(service_name, False)
|
|
88
88
|
|
|
89
89
|
@demo_message
|
|
90
|
-
def start(self, service_name,
|
|
90
|
+
def start(self, service_name, commit):
|
|
91
91
|
self._check_service(service_name)
|
|
92
92
|
time.sleep(DELAY)
|
|
93
93
|
self._stateDF = self._stateDF.with_columns(
|
|
@@ -98,7 +98,7 @@ class DemoCommands(Commands):
|
|
|
98
98
|
)
|
|
99
99
|
|
|
100
100
|
@demo_message
|
|
101
|
-
def stop(self, service_name,
|
|
101
|
+
def stop(self, service_name, commit):
|
|
102
102
|
self._check_service(service_name)
|
|
103
103
|
time.sleep(DELAY)
|
|
104
104
|
self._stateDF = self._stateDF.with_columns(
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/cmds/k8s_commands.py
RENAMED
|
@@ -24,8 +24,8 @@ class K8sCommands(Commands):
|
|
|
24
24
|
"""
|
|
25
25
|
|
|
26
26
|
params_opt_out = {
|
|
27
|
-
"stop": ["
|
|
28
|
-
"start": ["
|
|
27
|
+
"stop": ["commit"],
|
|
28
|
+
"start": ["commit"],
|
|
29
29
|
}
|
|
30
30
|
|
|
31
31
|
def __init__(
|
|
@@ -89,14 +89,14 @@ class K8sCommands(Commands):
|
|
|
89
89
|
f"kubectl delete -n {self.target} {pod_name}", skip_on_dryrun=True
|
|
90
90
|
)
|
|
91
91
|
|
|
92
|
-
def start(self, service_name,
|
|
92
|
+
def start(self, service_name, commit):
|
|
93
93
|
self._check_service(service_name)
|
|
94
94
|
shell.run_command(
|
|
95
95
|
f"kubectl scale -n {self.target} statefulset {service_name} --replicas=1",
|
|
96
96
|
skip_on_dryrun=True,
|
|
97
97
|
)
|
|
98
98
|
|
|
99
|
-
def stop(self, service_name,
|
|
99
|
+
def stop(self, service_name, commit):
|
|
100
100
|
self._check_service(service_name)
|
|
101
101
|
shell.run_command(
|
|
102
102
|
f"kubectl scale -n {self.target} statefulset {service_name} --replicas=0 ",
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli.egg-info/PKG-INFO
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: edge-containers-cli
|
|
3
|
-
Version: 4.
|
|
3
|
+
Version: 4.2.0
|
|
4
4
|
Summary: CLI for deploying and managing epics containers IOCs and services
|
|
5
5
|
Author-email: Giles Knap <giles.knap@gmail.com>
|
|
6
6
|
License: Apache License
|
|
@@ -250,7 +250,6 @@ https://epics-containers.github.io/
|
|
|
250
250
|
Source | <https://github.com/epics-containers/edge-containers-cli>
|
|
251
251
|
:---: | :---:
|
|
252
252
|
PyPI | `pip install edge-containers-cli`
|
|
253
|
-
Docker | `docker run ghcr.io/epics-containers/edge-containers-cli:latest`
|
|
254
253
|
Releases | <https://github.com/epics-containers/edge-containers-cli/releases>
|
|
255
254
|
|
|
256
255
|
|
|
@@ -36,7 +36,7 @@ restart:
|
|
|
36
36
|
- cmd: argocd app delete-resource namespace/bl01t-ea-test-01 --kind StatefulSet
|
|
37
37
|
rsp: ""
|
|
38
38
|
|
|
39
|
-
|
|
39
|
+
start_commit:
|
|
40
40
|
- cmd: argocd app get namespace/bl01t -o yaml
|
|
41
41
|
rsp: |
|
|
42
42
|
spec:
|
|
@@ -56,13 +56,13 @@ start:
|
|
|
56
56
|
- cmd: argocd app unset namespace/bl01t -p ec_services.bl01t-ea-test-01.enabled
|
|
57
57
|
rsp: ""
|
|
58
58
|
|
|
59
|
-
|
|
59
|
+
start:
|
|
60
60
|
- cmd: argocd app set namespace/bl01t -p ec_services.bl01t-ea-test-01.enabled=True
|
|
61
61
|
rsp: ""
|
|
62
62
|
- cmd: argocd app sync namespace/bl01t --apply-out-of-sync-only
|
|
63
63
|
rsp: ""
|
|
64
64
|
|
|
65
|
-
|
|
65
|
+
stop_commit:
|
|
66
66
|
- cmd: argocd app get namespace/bl01t -o yaml
|
|
67
67
|
rsp: |
|
|
68
68
|
spec:
|
|
@@ -76,7 +76,7 @@ stop:
|
|
|
76
76
|
- cmd: argocd app unset namespace/bl01t -p ec_services.bl01t-ea-test-01.enabled
|
|
77
77
|
rsp: ""
|
|
78
78
|
|
|
79
|
-
|
|
79
|
+
stop:
|
|
80
80
|
- cmd: argocd app set namespace/bl01t -p ec_services.bl01t-ea-test-01.enabled=False
|
|
81
81
|
rsp: ""
|
|
82
82
|
- cmd: argocd app sync namespace/bl01t --apply-out-of-sync-only
|
|
@@ -19,28 +19,28 @@ def test_restart(mock_run, ARGOCD):
|
|
|
19
19
|
mock_run.run_cli("restart bl01t-ea-test-01")
|
|
20
20
|
|
|
21
21
|
|
|
22
|
-
def
|
|
23
|
-
mock_run.set_seq(ARGOCD.checks + ARGOCD.
|
|
22
|
+
def test_start_commit(mock_run, ARGOCD, data: Path):
|
|
23
|
+
mock_run.set_seq(ARGOCD.checks + ARGOCD.start_commit)
|
|
24
24
|
TMPDIR.mkdir()
|
|
25
25
|
shutil.copytree(data / "bl01t-deployment/apps", TMPDIR / "apps")
|
|
26
|
-
mock_run.run_cli("start bl01t-ea-test-01")
|
|
26
|
+
mock_run.run_cli("start bl01t-ea-test-01 --commit")
|
|
27
27
|
|
|
28
28
|
|
|
29
|
-
def
|
|
30
|
-
mock_run.set_seq(ARGOCD.checks + ARGOCD.
|
|
31
|
-
mock_run.run_cli("start bl01t-ea-test-01
|
|
29
|
+
def test_start(mock_run, ARGOCD):
|
|
30
|
+
mock_run.set_seq(ARGOCD.checks + ARGOCD.start)
|
|
31
|
+
mock_run.run_cli("start bl01t-ea-test-01")
|
|
32
32
|
|
|
33
33
|
|
|
34
|
-
def
|
|
35
|
-
mock_run.set_seq(ARGOCD.checks + ARGOCD.
|
|
34
|
+
def test_stop_commit(mock_run, ARGOCD, data: Path):
|
|
35
|
+
mock_run.set_seq(ARGOCD.checks + ARGOCD.stop_commit)
|
|
36
36
|
TMPDIR.mkdir()
|
|
37
37
|
shutil.copytree(data / "bl01t-deployment/apps", TMPDIR / "apps")
|
|
38
|
-
mock_run.run_cli("stop bl01t-ea-test-01")
|
|
38
|
+
mock_run.run_cli("stop bl01t-ea-test-01 --commit")
|
|
39
39
|
|
|
40
40
|
|
|
41
|
-
def
|
|
42
|
-
mock_run.set_seq(ARGOCD.checks + ARGOCD.
|
|
43
|
-
mock_run.run_cli("stop bl01t-ea-test-01
|
|
41
|
+
def test_stop(mock_run, ARGOCD):
|
|
42
|
+
mock_run.set_seq(ARGOCD.checks + ARGOCD.stop)
|
|
43
|
+
mock_run.run_cli("stop bl01t-ea-test-01")
|
|
44
44
|
|
|
45
45
|
|
|
46
46
|
def test_ps(mock_run, ARGOCD):
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
on:
|
|
2
|
-
workflow_call:
|
|
3
|
-
|
|
4
|
-
jobs:
|
|
5
|
-
build:
|
|
6
|
-
runs-on: ubuntu-latest
|
|
7
|
-
|
|
8
|
-
steps:
|
|
9
|
-
- name: Checkout
|
|
10
|
-
uses: actions/checkout@v4
|
|
11
|
-
with:
|
|
12
|
-
# Need this to get version number from last tag
|
|
13
|
-
fetch-depth: 0
|
|
14
|
-
|
|
15
|
-
- name: Set up Docker Buildx
|
|
16
|
-
id: buildx
|
|
17
|
-
uses: docker/setup-buildx-action@v3
|
|
18
|
-
|
|
19
|
-
- name: Log in to GitHub Docker Registry
|
|
20
|
-
if: github.event_name != 'pull_request'
|
|
21
|
-
uses: docker/login-action@v3
|
|
22
|
-
with:
|
|
23
|
-
registry: ghcr.io
|
|
24
|
-
username: ${{ github.actor }}
|
|
25
|
-
password: ${{ secrets.GITHUB_TOKEN }}
|
|
26
|
-
|
|
27
|
-
- name: Build and export to Docker local cache
|
|
28
|
-
uses: docker/build-push-action@v6
|
|
29
|
-
env:
|
|
30
|
-
DOCKER_BUILD_RECORD_UPLOAD: false
|
|
31
|
-
with:
|
|
32
|
-
context: .
|
|
33
|
-
# Need load and tags so we can test it below
|
|
34
|
-
load: true
|
|
35
|
-
tags: tag_for_testing
|
|
36
|
-
|
|
37
|
-
- name: Test cli works in cached runtime image
|
|
38
|
-
run: docker run --rm tag_for_testing --help
|
|
39
|
-
|
|
40
|
-
- name: Create tags for publishing image
|
|
41
|
-
id: meta
|
|
42
|
-
uses: docker/metadata-action@v5
|
|
43
|
-
with:
|
|
44
|
-
images: ghcr.io/${{ github.repository }}
|
|
45
|
-
tags: |
|
|
46
|
-
type=ref,event=tag
|
|
47
|
-
type=raw,value=latest
|
|
48
|
-
|
|
49
|
-
- name: Push cached image to container registry
|
|
50
|
-
if: github.ref_type == 'tag'
|
|
51
|
-
uses: docker/build-push-action@v6
|
|
52
|
-
env:
|
|
53
|
-
DOCKER_BUILD_RECORD_UPLOAD: false
|
|
54
|
-
# This does not build the image again, it will find the image in the
|
|
55
|
-
# Docker cache and publish it
|
|
56
|
-
with:
|
|
57
|
-
context: .
|
|
58
|
-
push: true
|
|
59
|
-
tags: ${{ steps.meta.outputs.tags }}
|
|
60
|
-
labels: ${{ steps.meta.outputs.labels }}
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
# The devcontainer should use the developer target and run as root with podman
|
|
2
|
-
# or docker with user namespaces.
|
|
3
|
-
ARG PYTHON_VERSION=3.11
|
|
4
|
-
FROM python:${PYTHON_VERSION} as developer
|
|
5
|
-
|
|
6
|
-
# Add any system dependencies for the developer/build environment here
|
|
7
|
-
RUN apt-get update && apt-get install -y --no-install-recommends \
|
|
8
|
-
graphviz \
|
|
9
|
-
&& rm -rf /var/lib/apt/lists/*
|
|
10
|
-
|
|
11
|
-
# Set up a virtual environment and put it in PATH
|
|
12
|
-
RUN python -m venv /venv
|
|
13
|
-
ENV PATH=/venv/bin:$PATH
|
|
14
|
-
|
|
15
|
-
# The build stage installs the context into the venv
|
|
16
|
-
FROM developer as build
|
|
17
|
-
COPY . /context
|
|
18
|
-
WORKDIR /context
|
|
19
|
-
RUN touch dev-requirements.txt && pip install -c dev-requirements.txt .
|
|
20
|
-
|
|
21
|
-
# The runtime stage copies the built venv into a slim runtime container
|
|
22
|
-
FROM python:${PYTHON_VERSION}-slim as runtime
|
|
23
|
-
# Add apt-get system dependecies for runtime here if needed
|
|
24
|
-
COPY --from=build /venv/ /venv/
|
|
25
|
-
ENV PATH=/venv/bin:$PATH
|
|
26
|
-
RUN pip install textual-dev
|
|
27
|
-
|
|
28
|
-
# change this entrypoint if it is not the same as the repo
|
|
29
|
-
# Usage: serve "ec -b DEMO monitor" -p 8081
|
|
30
|
-
ENTRYPOINT ["textual", "serve"]
|
|
31
|
-
CMD ["--version"]
|
|
File without changes
|
|
File without changes
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/.github/ISSUE_TEMPLATE/bug_report.md
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/explanations/decisions.rst
RENAMED
|
File without changes
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/how-to/build-docs.rst
RENAMED
|
File without changes
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/how-to/contribute.rst
RENAMED
|
File without changes
|
|
File without changes
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/how-to/make-release.rst
RENAMED
|
File without changes
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/how-to/pin-requirements.rst
RENAMED
|
File without changes
|
|
File without changes
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/how-to/static-analysis.rst
RENAMED
|
File without changes
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/how-to/test-container.rst
RENAMED
|
File without changes
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/how-to/update-tools.rst
RENAMED
|
File without changes
|
|
File without changes
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/reference/standards.rst
RENAMED
|
File without changes
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/developer/tutorials/dev-install.rst
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/user/explanations/docs-structure.rst
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/docs/user/tutorials/installation.rst
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/autocomplete.py
RENAMED
|
File without changes
|
|
File without changes
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/cmds/__init__.py
RENAMED
|
File without changes
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/cmds/helm.py
RENAMED
|
File without changes
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/cmds/monitor.py
RENAMED
|
File without changes
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/cmds/monitor.tcss
RENAMED
|
File without changes
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/src/edge_containers_cli/definitions.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{edge_containers_cli-4.1.1 → edge_containers_cli-4.2.0}/tests/data/bl01t-deployment/apps/values.yaml
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|