Skip to content

Commit b4ab976

Browse files
Document pinned dw install path for CI and quickstarts
Add a "Pinned install for CI and quickstarts" section under the CLI install docs that shows the VERSION-pinned install command for each platform plus a GitHub Actions example. Both installer scripts already verify the release SHA256SUMS before replacing dw, so the docs point operators at a reproducible pinned flow without requiring a repo checkout. Cover three paths: - shell installer with VERSION=<tag> for Linux and macOS - PowerShell installer with $env:VERSION for Windows - PHAR download plus explicit sha256sum --check for shared PHP CI runners
1 parent dee2797 commit b4ab976

1 file changed

Lines changed: 69 additions & 0 deletions

File tree

docs/polyglot/cli.mdx

Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,75 @@ SDK, see [CLI and Python parity](/docs/2.0/polyglot/cli-python-parity).
3333
dw --version
3434
```
3535

36+
### Pinned install for CI and quickstarts
37+
38+
CI jobs and quickstart instructions should install a specific release rather
39+
than `latest`, so the same command produces the same `dw` binary every time
40+
and upgrades only when you change the pin.
41+
42+
Both installer scripts download `SHA256SUMS` from the release and verify the
43+
asset checksum before replacing `dw`, so a tampered mirror fails the install.
44+
45+
<details>
46+
<summary><b>Linux and macOS</b> (shell installer)</summary>
47+
48+
```bash
49+
VERSION=0.1.2 curl -fsSL https://durable-workflow.com/install.sh | sh
50+
dw --version
51+
```
52+
53+
`VERSION` accepts any published release tag. Leave it unset to install the
54+
latest release. Additional environment variables:
55+
56+
- `DURABLE_WORKFLOW_INSTALL_DIR` — install location (default `~/.local/bin`).
57+
- `DURABLE_WORKFLOW_BIN_NAME` — installed executable name (default `dw`).
58+
59+
A GitHub Actions example:
60+
61+
```yaml
62+
- name: Install Durable Workflow CLI
63+
run: |
64+
curl -fsSL https://durable-workflow.com/install.sh | VERSION=0.1.2 sh
65+
echo "$HOME/.local/bin" >> "$GITHUB_PATH"
66+
- name: Verify
67+
run: dw --version
68+
```
69+
70+
</details>
71+
72+
<details>
73+
<summary><b>Windows</b> (PowerShell installer)</summary>
74+
75+
```powershell
76+
$env:VERSION = "0.1.2"
77+
irm https://durable-workflow.com/install.ps1 | iex
78+
dw --version
79+
```
80+
81+
The installer writes `dw.exe` to `%USERPROFILE%\.durable-workflow\bin` and adds
82+
that directory to the user `PATH`.
83+
84+
</details>
85+
86+
<details>
87+
<summary><b>PHAR</b> (portable, requires PHP 8.2+)</summary>
88+
89+
```bash
90+
VERSION=0.1.2
91+
curl -fsSL -o dw.phar \
92+
"https://github.com/durable-workflow/cli/releases/download/${VERSION}/dw.phar"
93+
curl -fsSL -o SHA256SUMS \
94+
"https://github.com/durable-workflow/cli/releases/download/${VERSION}/SHA256SUMS"
95+
sha256sum --check --ignore-missing SHA256SUMS
96+
chmod +x dw.phar
97+
./dw.phar --version
98+
```
99+
100+
The PHAR works wherever PHP 8.2 or newer is already available and is the
101+
recommended artifact for shared CI runners that already ship PHP.
102+
103+
</details>
104+
36105
## Configure
37106

38107
Point the CLI at your server:

0 commit comments

Comments
 (0)