@@ -10,13 +10,12 @@ repositories. The provenance objects will be available through the Simple API an
1010Attestations can be uploaded to Pulp with its package as a JSON list under the field ` attestations ` .
1111
1212``` bash
13- att=$( jq ' [.]' twine-6.2.0.tar.gz.publish.attestation)
14- # multiple attestation files can be combined using --slurp and '.', jq --slurp '.' att1 att2 ...
15- http POST $PULP_API /pulp/api/v3/content/python/packages/ \
16- repository=" $PYTHON_REPO_HREF " \
17- relative_path=twine-6.2.0.tar.gz \
18- artifact=$PACKAGE_ARTIFACT_PRN \
19- attestations:=" $att "
13+ pulp python content create \
14+ --relative-path twine-6.2.0.tar.gz \
15+ --file twine-6.2.0.tar.gz \
16+ --repository $REPO_PRN \
17+ --attestation @twine-6.2.0.tar.gz.publish.attestation
18+ # --attestation can be specified multiple times to attach many attestations with a package
2019```
2120
2221The uploaded attestations can be found in the created Provenance object attached to the content in
@@ -61,10 +60,11 @@ twine upload --repository-url $PULP_API/pypi/foo/simple/ --attestations dist/*
6160Provenance content can be directly uploaded to Pulp through its content endpoint.
6261
6362``` bash
64- http POST $PULP_API /pulp/api/v3/content/python/provenance/ --form \
65- file@twine.provenance \
66- package=" $PACKAGE_PRN " \
67- repository=" $REPO_PRN "
63+ pulp python content -t provenance create \
64+ --file twine.provenance \
65+ --package $TWINE_PRN \
66+ --repository $REPO_PRN
67+ # you can also specify a package through its sha256
6868```
6969
7070Provenance objects are artifactless content, their data is stored in a json field and are unique by
@@ -75,7 +75,7 @@ one. Since provenance objects are content they can be added, removed, and synced
7575To sync provenance objects from an upstream repository set the ` provenance ` field on the remote.
7676
7777``` bash
78- http PATCH $PULP_API / $FOO_REMOTE_HREF provenance=true
78+ pulp python remote update --name foo -- provenance
7979pulp python repository sync --repository foo --remote foo
8080```
8181
0 commit comments