devlift-cli 0.1.4__tar.gz → 0.1.5__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.
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/PKG-INFO +1 -1
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/MANUAL.md +10 -2
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/__init__.py +1 -1
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/commands/eks.py +28 -4
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/skill/SKILL.md +10 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/skill/reference/commands.md +1 -1
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/skill/reference/workflows.md +3 -1
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli.egg-info/PKG-INFO +1 -1
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/README.md +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/__main__.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/api/__init__.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/api/approvals.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/api/catalog.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/api/client.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/api/context.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/api/deployments.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/api/infra.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/api/infra_list.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/api/kong.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/api/services.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/api/vpc.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/app.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/auth/__init__.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/auth/oauth.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/auth/session.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/auth/storage.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/commands/__init__.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/commands/approval.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/commands/auth.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/commands/catalog.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/commands/clusters.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/commands/deployment.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/commands/dynamodb.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/commands/kong.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/commands/languages.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/commands/manual.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/commands/repositories.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/commands/request.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/commands/s3.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/commands/skill.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/commands/sqs.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/config.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/context.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/data/placement/vance.json +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/errors.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/ops/__init__.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/ops/approvals.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/ops/eks.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/ops/kong.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/ops/placement.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/ops/resources.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/ops/status.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/ops/wait.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/render/__init__.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/render/output.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/resolve/__init__.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/resolve/allowlist.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/resolve/names.py +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli/skill/reference/exit-codes.md +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli.egg-info/SOURCES.txt +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli.egg-info/dependency_links.txt +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli.egg-info/entry_points.txt +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli.egg-info/requires.txt +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/devlift_cli.egg-info/top_level.txt +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/pyproject.toml +0 -0
- {devlift_cli-0.1.4 → devlift_cli-0.1.5}/setup.cfg +0 -0
|
@@ -509,7 +509,7 @@ devlift eks create --name NAME --app APP --env ENV --region REGION --type api|wo
|
|
|
509
509
|
[--set key=value ...] [--public] [-y]
|
|
510
510
|
devlift eks settings Every key --set accepts, and when each applies.
|
|
511
511
|
devlift eks settings <service> Only the keys that apply to it, with its current values.
|
|
512
|
-
devlift eks show <service> --env ENV The configuration
|
|
512
|
+
devlift eks show <service> --env ENV The configuration, with any pending draft over it; pending rows name the deployed value too.
|
|
513
513
|
devlift eks diff <service> --env ENV Preview the pending change: Field | Deployed | Requested.
|
|
514
514
|
devlift eks diff <service> --deployed The live configuration versus the last deployment.
|
|
515
515
|
devlift eks edit <service> --env ENV [--set key=value ...]
|
|
@@ -752,7 +752,15 @@ last deployed. That one ignores drafts entirely, so on a service whose
|
|
|
752
752
|
change is still a draft it shows the live row and its defaults, not what the
|
|
753
753
|
draft proposes.
|
|
754
754
|
|
|
755
|
-
|
|
755
|
+
**`eks show` is not "what is deployed" while a request is open.** Its
|
|
756
|
+
Configuration table is the live configuration with the open draft laid over
|
|
757
|
+
it, so a pending row shows the value the draft *proposes*. Each such row is
|
|
758
|
+
marked `pending (<status>) — deployed <value>`, so both numbers are visible.
|
|
759
|
+
|
|
760
|
+
In `-o json` the same thing is spelled out: `settings` is the merged view,
|
|
761
|
+
`deployed_settings` is what is actually running, and `pending` gives
|
|
762
|
+
`{deployed, requested}` for each changed key. When `pending_request` is null
|
|
763
|
+
there is no draft and `settings` is simply the deployed configuration.
|
|
756
764
|
|
|
757
765
|
### kong
|
|
758
766
|
|
|
@@ -110,13 +110,19 @@ def eks_show(
|
|
|
110
110
|
region: str | None = typer.Option(None, "--region", help="Region, when the service runs in several."),
|
|
111
111
|
):
|
|
112
112
|
"""Show a service's configuration as it stands, marking values pending in an open request."""
|
|
113
|
-
from devlift_cli.ops.eks import LABELS, load_effective, _show
|
|
113
|
+
from devlift_cli.ops.eks import LABELS, load_effective, settings_from_config, _show
|
|
114
114
|
from devlift_cli.render import output
|
|
115
115
|
|
|
116
116
|
inv: Invocation = ctx.obj
|
|
117
117
|
eff = load_effective(inv, Resolver(inv.api, inv.profile.name), service, env, region, for_edit=False)
|
|
118
118
|
live = eff.live
|
|
119
119
|
request = eff.draft
|
|
120
|
+
# `eff.settings` is the live config with the open draft laid OVER it, so for
|
|
121
|
+
# any pending key its value is what the draft proposes, not what is running.
|
|
122
|
+
# Reading it as "the current configuration" is the obvious mistake, and one
|
|
123
|
+
# that has been made, so the deployed values are published beside it rather
|
|
124
|
+
# than left to be inferred from pending_keys.
|
|
125
|
+
deployed_settings = settings_from_config(dict(live.get("config") or {}))
|
|
120
126
|
data = {
|
|
121
127
|
"service": eff.target.service_name, "service_config_code": eff.target.config_code,
|
|
122
128
|
"environment": live.get("environment"), "region": eff.target.region_name,
|
|
@@ -129,8 +135,19 @@ def eks_show(
|
|
|
129
135
|
"type": eff.service.get("service_type"), "repository": eff.config.get("repository"),
|
|
130
136
|
"branches": eff.config.get("branches") or eff.config.get("selected_branches"),
|
|
131
137
|
"language": f"{eff.language_label or ''} {eff.language_version or ''}".strip() or None,
|
|
132
|
-
|
|
138
|
+
# effective = deployed, with the pending draft laid over it.
|
|
139
|
+
"settings": eff.settings,
|
|
140
|
+
# what is actually running right now, whatever is pending.
|
|
141
|
+
"deployed_settings": deployed_settings,
|
|
142
|
+
"pending_request": {"code": request["code"], "status": request["status"]} if request else None,
|
|
133
143
|
"pending_keys": sorted(eff.pending_keys),
|
|
144
|
+
# Both sides per changed setting, so "what is deployed" needs no
|
|
145
|
+
# cross-referencing of two dicts against a list of keys.
|
|
146
|
+
"pending": {
|
|
147
|
+
k: {"deployed": deployed_settings.get(k), "requested": eff.settings.get(k)}
|
|
148
|
+
for k in sorted(eff.settings)
|
|
149
|
+
if k in eff.pending_keys or (k in ("hpa_enabled", "min_replicas", "max_replicas") and "hpa" in eff.pending_keys)
|
|
150
|
+
} if request else {},
|
|
134
151
|
}
|
|
135
152
|
|
|
136
153
|
def table(d):
|
|
@@ -145,8 +162,15 @@ def eks_show(
|
|
|
145
162
|
pend = set(d["pending_keys"])
|
|
146
163
|
def mark(k):
|
|
147
164
|
hit = k in pend or (k in ("hpa_enabled", "min_replicas", "max_replicas") and "hpa" in pend)
|
|
148
|
-
|
|
149
|
-
|
|
165
|
+
if not (hit and d["pending_request"]):
|
|
166
|
+
return ""
|
|
167
|
+
# Name the value that is actually running. Marking the row "pending"
|
|
168
|
+
# while showing only the draft's number tells the reader the setting
|
|
169
|
+
# is changing but not what it is changing FROM, which is the half
|
|
170
|
+
# they need to judge it.
|
|
171
|
+
return f"pending ({d['pending_request']['status']}) — deployed {_show(d['deployed_settings'].get(k))}"
|
|
172
|
+
header = "Value (deployed)" if not d["pending_request"] else "Value (with pending draft)"
|
|
173
|
+
return rows_table(["Setting", header, ""], [(LABELS.get(k, k), _show(v), mark(k)) for k, v in d["settings"].items()], title="Configuration")
|
|
150
174
|
inv.emit(data, table)
|
|
151
175
|
|
|
152
176
|
|
|
@@ -239,6 +239,16 @@ the approved rows. The summary is printed on every dry run, in json mode too.
|
|
|
239
239
|
finished, and `eks status <service> --env <env>` also asks ArgoCD whether the
|
|
240
240
|
pod is actually serving, which is the real "is it up" question. A finished
|
|
241
241
|
pipeline is not a running application.
|
|
242
|
+
- **`eks show` is not "what is deployed" when a request is open.** Its
|
|
243
|
+
`settings` are the live configuration with the open draft laid OVER it, so
|
|
244
|
+
for any pending key the value shown is what the draft PROPOSES. Quoting one
|
|
245
|
+
as the running value is wrong and has misled a user.
|
|
246
|
+
Check `pending_request` first. If it is null, `settings` is the deployed
|
|
247
|
+
configuration and you can quote it freely. If it is set, use
|
|
248
|
+
`deployed_settings` for what is running, or `pending` which gives
|
|
249
|
+
`{deployed, requested}` per changed key, or run `devlift eks diff <service>
|
|
250
|
+
--env <env>`. Never describe a value as current, running or deployed on the
|
|
251
|
+
strength of `settings` alone while something is pending.
|
|
242
252
|
- **Never compare a cluster code with a cluster name.** `eks show` returns both
|
|
243
253
|
`cluster` (the name, e.g. `acme-core-stage-mumbai-01-application-cluster`)
|
|
244
254
|
and `cluster_code` (e.g. `infra-acme-eks-staging-mumbai-app-01`). They are
|
|
@@ -63,7 +63,7 @@ devlift eks create --name NAME --app APP --env ENV --region REGION --type api|wo
|
|
|
63
63
|
--repository owner/name --branch main [--branch ...]
|
|
64
64
|
--language Go|Python|Node.js|"Java Maven"|"Java Gradle" --version 1.24
|
|
65
65
|
[--set key=value ...] [--public] [-y]
|
|
66
|
-
devlift eks show <service> --env ENV
|
|
66
|
+
devlift eks show <service> --env ENV live config WITH any open draft over it; deployed_settings + pending{} give the real deployed values
|
|
67
67
|
devlift eks diff <service> --env ENV preview the pending request: Field | Deployed | Requested
|
|
68
68
|
devlift eks diff <service> --deployed instead: live config vs the last deployment
|
|
69
69
|
devlift eks settings <service> --env ENV the --set keys that apply to it, with current values
|
|
@@ -59,7 +59,9 @@ the user it is a draft, nothing is deployed, and continue with workflow 6.
|
|
|
59
59
|
## 4. Change a running service's settings
|
|
60
60
|
|
|
61
61
|
```
|
|
62
|
-
devlift eks show orders --env stage --no-input -o json #
|
|
62
|
+
devlift eks show orders --env stage --no-input -o json # settings = live WITH the open draft over it.
|
|
63
|
+
# pending_request null -> settings IS the deployed config
|
|
64
|
+
# pending_request set -> use deployed_settings, or pending{key:{deployed,requested}}, or `eks diff`
|
|
63
65
|
devlift eks edit orders --env stage --set memory_limit=1 --no-input # Current | New, exit 5
|
|
64
66
|
devlift eks edit orders --env stage --set memory_limit=1 --no-input -y -o json
|
|
65
67
|
# → {changed, changes{field:{from,to}}, queue_code, queue_status}
|
|
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
|
|
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
|
|
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
|