cloudsmith-cli 1.16.0__tar.gz → 1.18.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.
- {cloudsmith_cli-1.16.0/cloudsmith_cli.egg-info → cloudsmith_cli-1.18.0}/PKG-INFO +167 -13
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/README.md +160 -12
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/__init__.py +1 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/mcp.py +128 -40
- cloudsmith_cli-1.18.0/cloudsmith_cli/cli/commands/metadata.py +503 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/cli/commands/push.py +1323 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/whoami.py +15 -22
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/config.py +92 -1
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/decorators.py +149 -18
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/exceptions.py +7 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/cli/metadata_common.py +146 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/saml.py +3 -5
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/commands/test_mcp.py +226 -2
- cloudsmith_cli-1.18.0/cloudsmith_cli/cli/tests/commands/test_metadata.py +699 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/conftest.py +4 -1
- cloudsmith_cli-1.18.0/cloudsmith_cli/cli/tests/test_metadata_common.py +123 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/cli/tests/test_push.py +1466 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/test_webserver.py +5 -1
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/utils.py +10 -1
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/webserver.py +10 -1
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/api/init.py +12 -66
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/api/metadata.py +217 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/api/packages.py +18 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/credentials/chain.py +69 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/credentials/models.py +42 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/credentials/oidc/__init__.py +6 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/credentials/oidc/cache.py +219 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/credentials/oidc/detectors/__init__.py +42 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/credentials/oidc/detectors/aws.py +84 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/credentials/oidc/detectors/base.py +25 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/credentials/oidc/exchange.py +87 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/credentials/provider.py +17 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/credentials/providers/__init__.py +15 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/credentials/providers/cli_flag.py +24 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/credentials/providers/credentials_file.py +24 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/credentials/providers/env_var.py +24 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/credentials/providers/keyring_provider.py +59 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/credentials/providers/oidc_provider.py +115 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/download.py +32 -44
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/keyring.py +31 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/mcp/data.py +3 -3
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/mcp/server.py +22 -22
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/pagination.py +6 -5
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/rest.py +16 -12
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/tests/__init__.py +0 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/tests/test_cli_flag_provider.py +46 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/tests/test_credential_chain_priority.py +135 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/tests/test_credential_context.py +30 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/tests/test_credential_provider_chain.py +80 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/tests/test_credentials_file_provider.py +47 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/tests/test_env_var_provider.py +45 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/tests/test_init.py +120 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/tests/test_keyring_provider.py +81 -0
- cloudsmith_cli-1.18.0/cloudsmith_cli/core/tests/test_metadata.py +605 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/tests/test_rest.py +24 -27
- cloudsmith_cli-1.18.0/cloudsmith_cli/data/VERSION +1 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0/cloudsmith_cli.egg-info}/PKG-INFO +167 -13
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli.egg-info/SOURCES.txt +29 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli.egg-info/requires.txt +7 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/setup.py +9 -0
- cloudsmith_cli-1.16.0/cloudsmith_cli/cli/commands/push.py +0 -692
- cloudsmith_cli-1.16.0/cloudsmith_cli/cli/tests/test_push.py +0 -245
- cloudsmith_cli-1.16.0/cloudsmith_cli/core/tests/test_init.py +0 -371
- cloudsmith_cli-1.16.0/cloudsmith_cli/data/VERSION +0 -1
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/LICENSE +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/MANIFEST.in +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/__init__.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/__main__.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/__init__.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/command.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/auth.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/check.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/copy.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/delete.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/dependencies.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/docs.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/download.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/entitlements.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/help_.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/list_.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/login.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/logout.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/main.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/metrics/__init__.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/metrics/command.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/metrics/entitlements.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/metrics/packages.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/move.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/policy/__init__.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/policy/command.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/policy/deny.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/policy/license.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/policy/vulnerability.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/quarantine.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/quota/__init__.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/quota/command.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/quota/history.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/quota/quota.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/repos.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/resync.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/status.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/tags.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/tokens.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/upstream.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/commands/vulnerabilities.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/table.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/__init__.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/commands/__init__.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/commands/conftest.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/commands/policy/__init__.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/commands/policy/test_deny.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/commands/policy/test_licence.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/commands/policy/test_vulnerability.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/commands/test_auth.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/commands/test_check.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/commands/test_download.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/commands/test_entitlements.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/commands/test_login.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/commands/test_logout.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/commands/test_main.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/commands/test_package_commands.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/commands/test_repos.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/commands/test_tokens.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/commands/test_upstream.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/commands/test_vulnerabilities.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/test_saml.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/test_utils.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/tests/utils.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/types.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/cli/validators.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/__init__.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/api/__init__.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/api/distros.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/api/entitlements.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/api/exceptions.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/api/files.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/api/metrics.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/api/orgs.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/api/quota.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/api/rates.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/api/repos.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/api/status.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/api/upstreams.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/api/user.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/api/version.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/api/vulnerabilities.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/config.py +0 -0
- {cloudsmith_cli-1.16.0/cloudsmith_cli/core/mcp → cloudsmith_cli-1.18.0/cloudsmith_cli/core/credentials}/__init__.py +0 -0
- {cloudsmith_cli-1.16.0/cloudsmith_cli/core/tests → cloudsmith_cli-1.18.0/cloudsmith_cli/core/mcp}/__init__.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/ratelimits.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/tests/test_download.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/tests/test_keyring.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/tests/test_version.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/utils.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/core/version.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/data/config.ini +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/data/credentials.ini +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/templates/__init__.py +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/templates/auth_error.html +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli/templates/auth_success.html +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli.egg-info/dependency_links.txt +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli.egg-info/entry_points.txt +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli.egg-info/not-zip-safe +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/cloudsmith_cli.egg-info/top_level.txt +0 -0
- {cloudsmith_cli-1.16.0 → cloudsmith_cli-1.18.0}/setup.cfg +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: cloudsmith-cli
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.18.0
|
|
4
4
|
Summary: Cloudsmith Command-Line Interface (CLI)
|
|
5
5
|
Home-page: https://github.com/cloudsmith-io/cloudsmith-cli
|
|
6
6
|
Author: Cloudsmith Ltd
|
|
@@ -34,12 +34,17 @@ Requires-Dist: json5>=0.9.0
|
|
|
34
34
|
Requires-Dist: cloudsmith-api<3.0,>=2.0.25
|
|
35
35
|
Requires-Dist: keyring>=25.4.1
|
|
36
36
|
Requires-Dist: mcp==1.9.1
|
|
37
|
+
Requires-Dist: PyJWT>=2.0.0
|
|
37
38
|
Requires-Dist: python-toon==0.1.2
|
|
38
39
|
Requires-Dist: requests>=2.18.4
|
|
39
40
|
Requires-Dist: requests_toolbelt>=1.0.0
|
|
40
41
|
Requires-Dist: rich>=13.0.0
|
|
41
42
|
Requires-Dist: semver>=2.7.9
|
|
42
43
|
Requires-Dist: urllib3>=2.5
|
|
44
|
+
Provides-Extra: aws
|
|
45
|
+
Requires-Dist: boto3[crt]>=1.26.0; extra == "aws"
|
|
46
|
+
Provides-Extra: all
|
|
47
|
+
Requires-Dist: boto3[crt]>=1.26.0; extra == "all"
|
|
43
48
|
Dynamic: author
|
|
44
49
|
Dynamic: author-email
|
|
45
50
|
Dynamic: classifier
|
|
@@ -50,6 +55,7 @@ Dynamic: keywords
|
|
|
50
55
|
Dynamic: license
|
|
51
56
|
Dynamic: license-file
|
|
52
57
|
Dynamic: platform
|
|
58
|
+
Dynamic: provides-extra
|
|
53
59
|
Dynamic: requires-dist
|
|
54
60
|
Dynamic: requires-python
|
|
55
61
|
Dynamic: summary
|
|
@@ -105,6 +111,11 @@ The CLI currently supports the following commands (and sub-commands):
|
|
|
105
111
|
- `repos`: List repositories for a namespace (owner).
|
|
106
112
|
- `login`|`token`: Retrieve your API authentication token/key via login.
|
|
107
113
|
- `logout`: Clear stored authentication credentials and SSO tokens (Keyring, API key from credential file and emit warning when `$CLOUDSMITH_API_KEY` is still set).
|
|
114
|
+
- `metadata`: Manage arbitrary JSON metadata (SBOM, BuildInfo, custom) attached to a package.
|
|
115
|
+
- `add`: Attach a new metadata entry to a package.
|
|
116
|
+
- `list`|`ls`: List metadata entries for a package, or fetch a single entry by slug.
|
|
117
|
+
- `update`: Replace content or source identity on an existing metadata entry.
|
|
118
|
+
- `remove`|`rm`: Remove a metadata entry from a package.
|
|
108
119
|
- `metrics`: Metrics and statistics for a repository.
|
|
109
120
|
- `tokens`: Retrieve bandwidth usage for entitlement tokens.
|
|
110
121
|
- `packages`: Retrieve package usage for repository.
|
|
@@ -192,6 +203,30 @@ Or you can get the latest pre-release version from Cloudsmith:
|
|
|
192
203
|
pip install --upgrade cloudsmith-cli --extra-index-url=https://dl.cloudsmith.io/public/cloudsmith/cli/python/index/
|
|
193
204
|
```
|
|
194
205
|
|
|
206
|
+
### Optional Dependencies
|
|
207
|
+
|
|
208
|
+
The CLI supports optional extras for additional functionality:
|
|
209
|
+
|
|
210
|
+
#### AWS OIDC Support
|
|
211
|
+
|
|
212
|
+
For AWS environments (ECS, EKS, EC2), install with `aws` extra to enable automatic credential discovery:
|
|
213
|
+
|
|
214
|
+
```
|
|
215
|
+
pip install cloudsmith-cli[aws]
|
|
216
|
+
```
|
|
217
|
+
|
|
218
|
+
This installs `boto3[crt]` for AWS credential chain support, STS token generation, and AWS SSO compatibility.
|
|
219
|
+
|
|
220
|
+
#### All Optional Features
|
|
221
|
+
|
|
222
|
+
To install all optional dependencies:
|
|
223
|
+
|
|
224
|
+
```
|
|
225
|
+
pip install cloudsmith-cli[all]
|
|
226
|
+
```
|
|
227
|
+
|
|
228
|
+
**Note:** If you don't install the AWS extra, the AWS OIDC detector will gracefully skip itself with no errors.
|
|
229
|
+
|
|
195
230
|
## Configuration
|
|
196
231
|
|
|
197
232
|
There are two configuration files used by the CLI:
|
|
@@ -298,7 +333,7 @@ Although native uploads, i.e. those supported by the native ecosystem of a packa
|
|
|
298
333
|
For example, if you wanted to upload a Debian package, you can do it in one-step. Assuming you have a package filename **libxml2-2.9.4-2.x86_64.deb**, representing **libxml 2.9.4**, for the **Ubuntu 16.04** distribution (which has a cloudsmith identifier of **ubuntu/xenial**):
|
|
299
334
|
|
|
300
335
|
```
|
|
301
|
-
cloudsmith push deb your-
|
|
336
|
+
cloudsmith push deb your-org/your-repo/ubuntu/xenial libxml2-2.9.4-2.x86_64.deb
|
|
302
337
|
```
|
|
303
338
|
|
|
304
339
|
Want to know how to do it with another packaging format? Easy, just ask for help:
|
|
@@ -315,39 +350,39 @@ You can download packages from repositories using the `cloudsmith download` comm
|
|
|
315
350
|
For example, to download a specific package:
|
|
316
351
|
|
|
317
352
|
```
|
|
318
|
-
cloudsmith download your-
|
|
353
|
+
cloudsmith download your-org/your-repo package-name
|
|
319
354
|
```
|
|
320
355
|
|
|
321
356
|
You can filter by various attributes like version, format, architecture, operating system, and tags:
|
|
322
357
|
|
|
323
358
|
```
|
|
324
359
|
# Download a specific version
|
|
325
|
-
cloudsmith download your-
|
|
360
|
+
cloudsmith download your-org/your-repo package-name --version 1.2.3
|
|
326
361
|
|
|
327
362
|
# Filter by format and architecture
|
|
328
|
-
cloudsmith download your-
|
|
363
|
+
cloudsmith download your-org/your-repo package-name --format deb --arch amd64
|
|
329
364
|
|
|
330
365
|
# Filter by package tag (e.g., latest, stable, beta)
|
|
331
|
-
cloudsmith download your-
|
|
366
|
+
cloudsmith download your-org/your-repo package-name --tag latest
|
|
332
367
|
|
|
333
368
|
# Combine tag with metadata filters
|
|
334
|
-
cloudsmith download your-
|
|
369
|
+
cloudsmith download your-org/your-repo package-name --tag stable --format deb --arch arm64
|
|
335
370
|
|
|
336
371
|
# Filter by filename (exact or glob pattern)
|
|
337
|
-
cloudsmith download your-
|
|
338
|
-
cloudsmith download your-
|
|
372
|
+
cloudsmith download your-org/your-repo package-name --filename '*.nupkg'
|
|
373
|
+
cloudsmith download your-org/your-repo package-name --filename 'mypackage-1.0.0.snupkg'
|
|
339
374
|
|
|
340
375
|
# Download all matching packages (when multiple packages share the same name/version)
|
|
341
|
-
cloudsmith download your-
|
|
376
|
+
cloudsmith download your-org/your-repo package-name --download-all
|
|
342
377
|
|
|
343
378
|
# Combine --download-all with --filename to download a subset
|
|
344
|
-
cloudsmith download your-
|
|
379
|
+
cloudsmith download your-org/your-repo package-name --download-all --filename '*.snupkg'
|
|
345
380
|
|
|
346
381
|
# Download all associated files (POM, sources, javadoc, etc.)
|
|
347
|
-
cloudsmith download your-
|
|
382
|
+
cloudsmith download your-org/your-repo package-name --all-files
|
|
348
383
|
|
|
349
384
|
# Preview what would be downloaded without actually downloading
|
|
350
|
-
cloudsmith download your-
|
|
385
|
+
cloudsmith download your-org/your-repo package-name --dry-run
|
|
351
386
|
```
|
|
352
387
|
|
|
353
388
|
For more advanced usage and all available options:
|
|
@@ -357,6 +392,125 @@ cloudsmith download --help
|
|
|
357
392
|
```
|
|
358
393
|
|
|
359
394
|
|
|
395
|
+
## Package Metadata
|
|
396
|
+
|
|
397
|
+
Arbitrary JSON metadata can be attached to any package — SBOMs, JFrog BuildInfo documents, or custom payloads. Metadata is validated against the declared content type and stays with the package for its lifetime.
|
|
398
|
+
|
|
399
|
+
Metadata can be attached at push time with `cloudsmith push` (see [Attaching Metadata During Push](#attaching-metadata-during-push)) or managed afterwards with the `cloudsmith metadata` command group.
|
|
400
|
+
|
|
401
|
+
To attach metadata to an existing package:
|
|
402
|
+
|
|
403
|
+
```
|
|
404
|
+
cloudsmith metadata add your-org/your-repo/your-pkg \
|
|
405
|
+
--content-type application/json \
|
|
406
|
+
--content '{"build_id": "demo-123", "git_sha": "abc123"}'
|
|
407
|
+
```
|
|
408
|
+
|
|
409
|
+
To attach metadata from a file (use `-` to read from stdin):
|
|
410
|
+
|
|
411
|
+
```
|
|
412
|
+
cloudsmith metadata add your-org/your-repo/your-pkg \
|
|
413
|
+
--content-type application/vnd.jfrog.buildinfo+json \
|
|
414
|
+
--file buildinfo.json
|
|
415
|
+
```
|
|
416
|
+
|
|
417
|
+
To list all metadata entries on a package, or fetch a single entry by slug:
|
|
418
|
+
|
|
419
|
+
```
|
|
420
|
+
cloudsmith metadata list your-org/your-repo/your-pkg
|
|
421
|
+
cloudsmith metadata list your-org/your-repo/your-pkg meta-slug-perm
|
|
422
|
+
```
|
|
423
|
+
|
|
424
|
+
Filter entries by source kind or classification when listing:
|
|
425
|
+
|
|
426
|
+
```
|
|
427
|
+
cloudsmith metadata list your-org/your-repo/your-pkg --classification sbom
|
|
428
|
+
cloudsmith metadata list your-org/your-repo/your-pkg --source-kind third_party
|
|
429
|
+
```
|
|
430
|
+
|
|
431
|
+
To replace the content or source identity of an existing entry (content type is fixed after creation):
|
|
432
|
+
|
|
433
|
+
```
|
|
434
|
+
cloudsmith metadata update your-org/your-repo/your-pkg meta-slug-perm \
|
|
435
|
+
--content '{"build_id": "demo-124"}'
|
|
436
|
+
```
|
|
437
|
+
|
|
438
|
+
To remove a metadata entry:
|
|
439
|
+
|
|
440
|
+
```
|
|
441
|
+
cloudsmith metadata remove your-org/your-repo/your-pkg meta-slug-perm
|
|
442
|
+
```
|
|
443
|
+
|
|
444
|
+
For all available options:
|
|
445
|
+
|
|
446
|
+
```
|
|
447
|
+
cloudsmith metadata --help
|
|
448
|
+
```
|
|
449
|
+
|
|
450
|
+
|
|
451
|
+
## Attaching Metadata During Push
|
|
452
|
+
|
|
453
|
+
Every `cloudsmith push <format>` subcommand accepts a set of `--metadata-*` flags. When provided, metadata is validated locally and against the API before any file upload, then attached to the package immediately after creation. This avoids a separate `cloudsmith metadata add` step and prevents malformed metadata from leaving orphan packages behind.
|
|
454
|
+
|
|
455
|
+
Available flags on every push subcommand:
|
|
456
|
+
|
|
457
|
+
- `--metadata-content-file PATH`: Path to a JSON file containing the metadata content. Use `-` for stdin.
|
|
458
|
+
- `--metadata-content JSON`: Inline JSON content. Mutually exclusive with `--metadata-content-file`.
|
|
459
|
+
- `--metadata-content-type MIME`: MIME type of the metadata payload (e.g. `application/json`, `application/vnd.jfrog.buildinfo+json`). Required when content is provided.
|
|
460
|
+
- `--metadata-source-identity TEXT`: Identifier indicating where the metadata originated. Defaults to `cloudsmith-cli@<version>`.
|
|
461
|
+
- `--on-metadata-failure [error|warn]`: How to handle push-time metadata failures for this push only. `error` (default) aborts the push so CI/CD surfaces broken SBOM/BuildInfo payloads; `warn` downgrades to a warning and lets the package upload regardless. Overrides `$CLOUDSMITH_METADATA_FAILURE_MODE` and the `metadata_failure_mode` config key.
|
|
462
|
+
|
|
463
|
+
Push a package with inline metadata:
|
|
464
|
+
|
|
465
|
+
```
|
|
466
|
+
cloudsmith push raw your-org/your-repo payload.txt \
|
|
467
|
+
--name demo --version 1.0.0 \
|
|
468
|
+
--metadata-content '{"build_id": "demo-inline", "git_sha": "abc123"}' \
|
|
469
|
+
--metadata-content-type application/json
|
|
470
|
+
```
|
|
471
|
+
|
|
472
|
+
Push a package with metadata loaded from a file:
|
|
473
|
+
|
|
474
|
+
```
|
|
475
|
+
cloudsmith push raw your-org/your-repo payload.txt \
|
|
476
|
+
--name demo --version 1.0.0 \
|
|
477
|
+
--metadata-content-file buildinfo.json \
|
|
478
|
+
--metadata-content-type application/vnd.jfrog.buildinfo+json
|
|
479
|
+
```
|
|
480
|
+
|
|
481
|
+
### Failure Behavior
|
|
482
|
+
|
|
483
|
+
By default, push aborts when metadata validation or attachment fails. The HTTP status from the failed request is used as the exit code, so CI pipelines surface broken SBOMs or BuildInfo payloads instead of silently uploading a package without metadata.
|
|
484
|
+
|
|
485
|
+
To downgrade failures to a warning (the package is still uploaded, and a copy-paste `cloudsmith metadata add` retry hint is printed), use any of the following — listed in order of precedence (highest first):
|
|
486
|
+
|
|
487
|
+
1. The `--on-metadata-failure warn` CLI flag on `cloudsmith push` (per-push override):
|
|
488
|
+
|
|
489
|
+
```
|
|
490
|
+
cloudsmith push raw your-org/your-repo payload.txt \
|
|
491
|
+
--name demo --version 1.0.0 \
|
|
492
|
+
--metadata-content-file buildinfo.json \
|
|
493
|
+
--metadata-content-type application/vnd.jfrog.buildinfo+json \
|
|
494
|
+
--on-metadata-failure warn
|
|
495
|
+
```
|
|
496
|
+
|
|
497
|
+
2. The `CLOUDSMITH_METADATA_FAILURE_MODE` environment variable set to `warn` or `0` (per-shell):
|
|
498
|
+
|
|
499
|
+
```
|
|
500
|
+
CLOUDSMITH_METADATA_FAILURE_MODE=warn cloudsmith push raw your-org/your-repo payload.txt \
|
|
501
|
+
--name demo --version 1.0.0 \
|
|
502
|
+
--metadata-content-file buildinfo.json \
|
|
503
|
+
--metadata-content-type application/vnd.jfrog.buildinfo+json
|
|
504
|
+
```
|
|
505
|
+
|
|
506
|
+
3. The `metadata_failure_mode` key in `config.ini` set to `error`, `warn`, or `0` (persistent default):
|
|
507
|
+
|
|
508
|
+
```ini
|
|
509
|
+
[default]
|
|
510
|
+
metadata_failure_mode = warn
|
|
511
|
+
```
|
|
512
|
+
|
|
513
|
+
|
|
360
514
|
## Contributing
|
|
361
515
|
|
|
362
516
|
Yes! Please do contribute, this is why we love open source. Please see [CONTRIBUTING](https://github.com/cloudsmith-io/cloudsmith-cli/blob/master/CONTRIBUTING.md) for contribution guidelines when making code changes or raising issues for bug reports, ideas, discussions and/or questions (i.e. help required).
|
|
@@ -49,6 +49,11 @@ The CLI currently supports the following commands (and sub-commands):
|
|
|
49
49
|
- `repos`: List repositories for a namespace (owner).
|
|
50
50
|
- `login`|`token`: Retrieve your API authentication token/key via login.
|
|
51
51
|
- `logout`: Clear stored authentication credentials and SSO tokens (Keyring, API key from credential file and emit warning when `$CLOUDSMITH_API_KEY` is still set).
|
|
52
|
+
- `metadata`: Manage arbitrary JSON metadata (SBOM, BuildInfo, custom) attached to a package.
|
|
53
|
+
- `add`: Attach a new metadata entry to a package.
|
|
54
|
+
- `list`|`ls`: List metadata entries for a package, or fetch a single entry by slug.
|
|
55
|
+
- `update`: Replace content or source identity on an existing metadata entry.
|
|
56
|
+
- `remove`|`rm`: Remove a metadata entry from a package.
|
|
52
57
|
- `metrics`: Metrics and statistics for a repository.
|
|
53
58
|
- `tokens`: Retrieve bandwidth usage for entitlement tokens.
|
|
54
59
|
- `packages`: Retrieve package usage for repository.
|
|
@@ -136,6 +141,30 @@ Or you can get the latest pre-release version from Cloudsmith:
|
|
|
136
141
|
pip install --upgrade cloudsmith-cli --extra-index-url=https://dl.cloudsmith.io/public/cloudsmith/cli/python/index/
|
|
137
142
|
```
|
|
138
143
|
|
|
144
|
+
### Optional Dependencies
|
|
145
|
+
|
|
146
|
+
The CLI supports optional extras for additional functionality:
|
|
147
|
+
|
|
148
|
+
#### AWS OIDC Support
|
|
149
|
+
|
|
150
|
+
For AWS environments (ECS, EKS, EC2), install with `aws` extra to enable automatic credential discovery:
|
|
151
|
+
|
|
152
|
+
```
|
|
153
|
+
pip install cloudsmith-cli[aws]
|
|
154
|
+
```
|
|
155
|
+
|
|
156
|
+
This installs `boto3[crt]` for AWS credential chain support, STS token generation, and AWS SSO compatibility.
|
|
157
|
+
|
|
158
|
+
#### All Optional Features
|
|
159
|
+
|
|
160
|
+
To install all optional dependencies:
|
|
161
|
+
|
|
162
|
+
```
|
|
163
|
+
pip install cloudsmith-cli[all]
|
|
164
|
+
```
|
|
165
|
+
|
|
166
|
+
**Note:** If you don't install the AWS extra, the AWS OIDC detector will gracefully skip itself with no errors.
|
|
167
|
+
|
|
139
168
|
## Configuration
|
|
140
169
|
|
|
141
170
|
There are two configuration files used by the CLI:
|
|
@@ -242,7 +271,7 @@ Although native uploads, i.e. those supported by the native ecosystem of a packa
|
|
|
242
271
|
For example, if you wanted to upload a Debian package, you can do it in one-step. Assuming you have a package filename **libxml2-2.9.4-2.x86_64.deb**, representing **libxml 2.9.4**, for the **Ubuntu 16.04** distribution (which has a cloudsmith identifier of **ubuntu/xenial**):
|
|
243
272
|
|
|
244
273
|
```
|
|
245
|
-
cloudsmith push deb your-
|
|
274
|
+
cloudsmith push deb your-org/your-repo/ubuntu/xenial libxml2-2.9.4-2.x86_64.deb
|
|
246
275
|
```
|
|
247
276
|
|
|
248
277
|
Want to know how to do it with another packaging format? Easy, just ask for help:
|
|
@@ -259,39 +288,39 @@ You can download packages from repositories using the `cloudsmith download` comm
|
|
|
259
288
|
For example, to download a specific package:
|
|
260
289
|
|
|
261
290
|
```
|
|
262
|
-
cloudsmith download your-
|
|
291
|
+
cloudsmith download your-org/your-repo package-name
|
|
263
292
|
```
|
|
264
293
|
|
|
265
294
|
You can filter by various attributes like version, format, architecture, operating system, and tags:
|
|
266
295
|
|
|
267
296
|
```
|
|
268
297
|
# Download a specific version
|
|
269
|
-
cloudsmith download your-
|
|
298
|
+
cloudsmith download your-org/your-repo package-name --version 1.2.3
|
|
270
299
|
|
|
271
300
|
# Filter by format and architecture
|
|
272
|
-
cloudsmith download your-
|
|
301
|
+
cloudsmith download your-org/your-repo package-name --format deb --arch amd64
|
|
273
302
|
|
|
274
303
|
# Filter by package tag (e.g., latest, stable, beta)
|
|
275
|
-
cloudsmith download your-
|
|
304
|
+
cloudsmith download your-org/your-repo package-name --tag latest
|
|
276
305
|
|
|
277
306
|
# Combine tag with metadata filters
|
|
278
|
-
cloudsmith download your-
|
|
307
|
+
cloudsmith download your-org/your-repo package-name --tag stable --format deb --arch arm64
|
|
279
308
|
|
|
280
309
|
# Filter by filename (exact or glob pattern)
|
|
281
|
-
cloudsmith download your-
|
|
282
|
-
cloudsmith download your-
|
|
310
|
+
cloudsmith download your-org/your-repo package-name --filename '*.nupkg'
|
|
311
|
+
cloudsmith download your-org/your-repo package-name --filename 'mypackage-1.0.0.snupkg'
|
|
283
312
|
|
|
284
313
|
# Download all matching packages (when multiple packages share the same name/version)
|
|
285
|
-
cloudsmith download your-
|
|
314
|
+
cloudsmith download your-org/your-repo package-name --download-all
|
|
286
315
|
|
|
287
316
|
# Combine --download-all with --filename to download a subset
|
|
288
|
-
cloudsmith download your-
|
|
317
|
+
cloudsmith download your-org/your-repo package-name --download-all --filename '*.snupkg'
|
|
289
318
|
|
|
290
319
|
# Download all associated files (POM, sources, javadoc, etc.)
|
|
291
|
-
cloudsmith download your-
|
|
320
|
+
cloudsmith download your-org/your-repo package-name --all-files
|
|
292
321
|
|
|
293
322
|
# Preview what would be downloaded without actually downloading
|
|
294
|
-
cloudsmith download your-
|
|
323
|
+
cloudsmith download your-org/your-repo package-name --dry-run
|
|
295
324
|
```
|
|
296
325
|
|
|
297
326
|
For more advanced usage and all available options:
|
|
@@ -301,6 +330,125 @@ cloudsmith download --help
|
|
|
301
330
|
```
|
|
302
331
|
|
|
303
332
|
|
|
333
|
+
## Package Metadata
|
|
334
|
+
|
|
335
|
+
Arbitrary JSON metadata can be attached to any package — SBOMs, JFrog BuildInfo documents, or custom payloads. Metadata is validated against the declared content type and stays with the package for its lifetime.
|
|
336
|
+
|
|
337
|
+
Metadata can be attached at push time with `cloudsmith push` (see [Attaching Metadata During Push](#attaching-metadata-during-push)) or managed afterwards with the `cloudsmith metadata` command group.
|
|
338
|
+
|
|
339
|
+
To attach metadata to an existing package:
|
|
340
|
+
|
|
341
|
+
```
|
|
342
|
+
cloudsmith metadata add your-org/your-repo/your-pkg \
|
|
343
|
+
--content-type application/json \
|
|
344
|
+
--content '{"build_id": "demo-123", "git_sha": "abc123"}'
|
|
345
|
+
```
|
|
346
|
+
|
|
347
|
+
To attach metadata from a file (use `-` to read from stdin):
|
|
348
|
+
|
|
349
|
+
```
|
|
350
|
+
cloudsmith metadata add your-org/your-repo/your-pkg \
|
|
351
|
+
--content-type application/vnd.jfrog.buildinfo+json \
|
|
352
|
+
--file buildinfo.json
|
|
353
|
+
```
|
|
354
|
+
|
|
355
|
+
To list all metadata entries on a package, or fetch a single entry by slug:
|
|
356
|
+
|
|
357
|
+
```
|
|
358
|
+
cloudsmith metadata list your-org/your-repo/your-pkg
|
|
359
|
+
cloudsmith metadata list your-org/your-repo/your-pkg meta-slug-perm
|
|
360
|
+
```
|
|
361
|
+
|
|
362
|
+
Filter entries by source kind or classification when listing:
|
|
363
|
+
|
|
364
|
+
```
|
|
365
|
+
cloudsmith metadata list your-org/your-repo/your-pkg --classification sbom
|
|
366
|
+
cloudsmith metadata list your-org/your-repo/your-pkg --source-kind third_party
|
|
367
|
+
```
|
|
368
|
+
|
|
369
|
+
To replace the content or source identity of an existing entry (content type is fixed after creation):
|
|
370
|
+
|
|
371
|
+
```
|
|
372
|
+
cloudsmith metadata update your-org/your-repo/your-pkg meta-slug-perm \
|
|
373
|
+
--content '{"build_id": "demo-124"}'
|
|
374
|
+
```
|
|
375
|
+
|
|
376
|
+
To remove a metadata entry:
|
|
377
|
+
|
|
378
|
+
```
|
|
379
|
+
cloudsmith metadata remove your-org/your-repo/your-pkg meta-slug-perm
|
|
380
|
+
```
|
|
381
|
+
|
|
382
|
+
For all available options:
|
|
383
|
+
|
|
384
|
+
```
|
|
385
|
+
cloudsmith metadata --help
|
|
386
|
+
```
|
|
387
|
+
|
|
388
|
+
|
|
389
|
+
## Attaching Metadata During Push
|
|
390
|
+
|
|
391
|
+
Every `cloudsmith push <format>` subcommand accepts a set of `--metadata-*` flags. When provided, metadata is validated locally and against the API before any file upload, then attached to the package immediately after creation. This avoids a separate `cloudsmith metadata add` step and prevents malformed metadata from leaving orphan packages behind.
|
|
392
|
+
|
|
393
|
+
Available flags on every push subcommand:
|
|
394
|
+
|
|
395
|
+
- `--metadata-content-file PATH`: Path to a JSON file containing the metadata content. Use `-` for stdin.
|
|
396
|
+
- `--metadata-content JSON`: Inline JSON content. Mutually exclusive with `--metadata-content-file`.
|
|
397
|
+
- `--metadata-content-type MIME`: MIME type of the metadata payload (e.g. `application/json`, `application/vnd.jfrog.buildinfo+json`). Required when content is provided.
|
|
398
|
+
- `--metadata-source-identity TEXT`: Identifier indicating where the metadata originated. Defaults to `cloudsmith-cli@<version>`.
|
|
399
|
+
- `--on-metadata-failure [error|warn]`: How to handle push-time metadata failures for this push only. `error` (default) aborts the push so CI/CD surfaces broken SBOM/BuildInfo payloads; `warn` downgrades to a warning and lets the package upload regardless. Overrides `$CLOUDSMITH_METADATA_FAILURE_MODE` and the `metadata_failure_mode` config key.
|
|
400
|
+
|
|
401
|
+
Push a package with inline metadata:
|
|
402
|
+
|
|
403
|
+
```
|
|
404
|
+
cloudsmith push raw your-org/your-repo payload.txt \
|
|
405
|
+
--name demo --version 1.0.0 \
|
|
406
|
+
--metadata-content '{"build_id": "demo-inline", "git_sha": "abc123"}' \
|
|
407
|
+
--metadata-content-type application/json
|
|
408
|
+
```
|
|
409
|
+
|
|
410
|
+
Push a package with metadata loaded from a file:
|
|
411
|
+
|
|
412
|
+
```
|
|
413
|
+
cloudsmith push raw your-org/your-repo payload.txt \
|
|
414
|
+
--name demo --version 1.0.0 \
|
|
415
|
+
--metadata-content-file buildinfo.json \
|
|
416
|
+
--metadata-content-type application/vnd.jfrog.buildinfo+json
|
|
417
|
+
```
|
|
418
|
+
|
|
419
|
+
### Failure Behavior
|
|
420
|
+
|
|
421
|
+
By default, push aborts when metadata validation or attachment fails. The HTTP status from the failed request is used as the exit code, so CI pipelines surface broken SBOMs or BuildInfo payloads instead of silently uploading a package without metadata.
|
|
422
|
+
|
|
423
|
+
To downgrade failures to a warning (the package is still uploaded, and a copy-paste `cloudsmith metadata add` retry hint is printed), use any of the following — listed in order of precedence (highest first):
|
|
424
|
+
|
|
425
|
+
1. The `--on-metadata-failure warn` CLI flag on `cloudsmith push` (per-push override):
|
|
426
|
+
|
|
427
|
+
```
|
|
428
|
+
cloudsmith push raw your-org/your-repo payload.txt \
|
|
429
|
+
--name demo --version 1.0.0 \
|
|
430
|
+
--metadata-content-file buildinfo.json \
|
|
431
|
+
--metadata-content-type application/vnd.jfrog.buildinfo+json \
|
|
432
|
+
--on-metadata-failure warn
|
|
433
|
+
```
|
|
434
|
+
|
|
435
|
+
2. The `CLOUDSMITH_METADATA_FAILURE_MODE` environment variable set to `warn` or `0` (per-shell):
|
|
436
|
+
|
|
437
|
+
```
|
|
438
|
+
CLOUDSMITH_METADATA_FAILURE_MODE=warn cloudsmith push raw your-org/your-repo payload.txt \
|
|
439
|
+
--name demo --version 1.0.0 \
|
|
440
|
+
--metadata-content-file buildinfo.json \
|
|
441
|
+
--metadata-content-type application/vnd.jfrog.buildinfo+json
|
|
442
|
+
```
|
|
443
|
+
|
|
444
|
+
3. The `metadata_failure_mode` key in `config.ini` set to `error`, `warn`, or `0` (persistent default):
|
|
445
|
+
|
|
446
|
+
```ini
|
|
447
|
+
[default]
|
|
448
|
+
metadata_failure_mode = warn
|
|
449
|
+
```
|
|
450
|
+
|
|
451
|
+
|
|
304
452
|
## Contributing
|
|
305
453
|
|
|
306
454
|
Yes! Please do contribute, this is why we love open source. Please see [CONTRIBUTING](https://github.com/cloudsmith-io/cloudsmith-cli/blob/master/CONTRIBUTING.md) for contribution guidelines when making code changes or raising issues for bug reports, ideas, discussions and/or questions (i.e. help required).
|