You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/docs/getting-started/workflow-definition.mdx
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -24,7 +24,7 @@ A workflow represents the identity of any automation, any CI/CD workflow you wan
24
24
25
25
### Chainloop API Token
26
26
27
-
A [Chainloop API Token](/reference/operator/api-tokens) is a long-lasting, though revokable, **secret token associated with a Chainloop organization**. It's meant to be used in the target CI/CD pipeline during the attestation process and/or for unatended operations with the controlplane. This token along with the crafting CLI are the only two things development teams need to perform attestations.
27
+
A [Chainloop API Token](/reference/operator/api-tokens) is a long-lasting, though revokable, **secret token associated with a Chainloop organization**. It's meant to be used in the target CI/CD pipeline during the attestation process and/or for unattended operations with the controlplane. This token along with the crafting CLI are the only two things development teams need to perform attestations.
for a complete explanation of Workflows and Contracts.
28
+
29
+
3. Create a new Chainloop Workflow.
30
+
31
+
Chainloop workflows represent any CI or process you might want to attest. Check [this doc](/getting-started/workflow-definition) for a complete explanation of Workflows and Contracts.
29
32
You might also want to check our [contract reference](/reference/operator/contract).
CHAINLOOP_TOKEN environment variable is commonly used from CI/CD scenarios, where a personal token is not available.
36
-
Tokens have narrower permissions, ensuring that they can only perform the operations they are granted to.
37
-
More information in [API Tokens](/reference/operator/api-tokens#api-tokens).
38
46
39
-
5. Perform an attestation:
47
+
Chainloop API Tokens are commonly used (and required) in CI/CD scenarios. Tokens have narrower permissions, ensuring that they can only perform the operations they are granted to. More information in [API Tokens](/reference/operator/api-tokens#api-tokens).
48
+
49
+
5. Perform an attestation process:
50
+
51
+
We are now ready to perform our first attestation, to learn more about its lifecyle refer to [this section](/getting-started/attestation-crafting#introduction)
40
52
41
-
First, let's [initiate the attestation](/getting-started/attestation-crafting#initialization).
53
+
We'll start with the [initialization](/getting-started/attestation-crafting#initialization) of an attestation for our previously created workflow (`mywf`)
54
+
42
55
```bash
43
-
chainloop att init --workflow-name mywf
56
+
chainloop att init --name mywf
44
57
```
45
58
46
59
Once attestation is initiated, we can start [adding materials](/getting-started/attestation-crafting#adding-materials) to it.
47
60
In this case we are adding an OCI container image.
48
61
Many other material types are supported, check the [updated the list](/reference/operator/contract#material-schema)
62
+
63
+
```bash
64
+
chainloop att add --value ghcr.io/chainloop-dev/chainloop/control-plane:latest
65
+
```
66
+
67
+
We just attested the latest version of the control-plane image as an example, remember that you can provide any material you want to attest by pointing to a local filepath too, like for example
68
+
49
69
```bash
50
-
chainloop att add --value "ghcr.io/chainloop-dev/chainloop/control-plane:latest"
70
+
chainloop att add --value my-sbom.json
51
71
```
52
72
53
73
And finally [we sign and push the attestation](/getting-started/attestation-crafting#encode-sign-and-push-attestation) to Chainloop for permanent preservation.
74
+
54
75
```bash
55
76
chainloop att push
56
77
```
57
-
Note that, in this example, we are not specifying any private key for signing.
58
-
This will make the CLI to work in key-less mode, generating an ephemeral certificate,
59
-
signed by Chainloop CA, to ensure the trust chain, and finally using it for the signature.
78
+
79
+
6. Operate on your data:
80
+
81
+
At this point, we've performed our first attestation, now we can just play with the Chainloop CLI to inspect the attestation, verify it and so on.
82
+
83
+
For example, to list the workflows you can run:
84
+
85
+
```bash
86
+
# List workflow runs, so then you can do `workflow run describe --id <id>` to get more details
87
+
chainloop workflow run ls
88
+
```
89
+
90
+
for a complete list of available options and operations refer to
91
+
92
+
```
93
+
chainloop --help
94
+
```
95
+
96
+
Great! You've successfully completed this guide. Now you are ready to dive deeper into our [Getting Started guide](/getting-started/installation)
0 commit comments