Installation
Prebuilt binary, source build, or Docker.
Prebuilt binary
Each v* tag publishes static, CGO-free binaries on the
Releases page for
linux/darwin × amd64/arm64.
# Linux x86-64 (swap the suffix for your platform)
curl -sSL -o cli2api \
https://github.com/yeagoo/MuleRunCLI2API/releases/latest/download/cli2api-linux-amd64
chmod +x cli2api
./cli2api --versionEach release publishes two names per platform: a versioned one
(cli2api-<version>-{linux,darwin}-{amd64,arm64}, e.g.
cli2api-v0.1.0-linux-amd64) for archival, and a stable one
(cli2api-{linux,darwin}-{amd64,arm64}) that the latest/download/... URL
above always resolves to. Each has a .sha256 sidecar, plus an aggregate
SHA256SUMS.txt:
sha256sum -c SHA256SUMS.txtFrom source
Requires Go ≥ 1.25.
git clone https://github.com/yeagoo/MuleRunCLI2API cli2api && cd cli2api
make build # version injected from `git describe --tags`
./bin/cli2api --versionDocker
docker compose up --builddocker-compose.yml documents two credential-injection styles:
- A —
MULERUN_TOKENenv var (simplest) - B — mount
~/.config/mulerun+~/.muleruninto the container (reuse the host's OAuth cache)
mulerun-cli ≥0.1.0 stores the token at ~/.config/mulerun/oauth_cache.json;
older versions at ~/.mulerun/. Mount whichever matches your installed version.
systemd
[Unit]
Description=cli2api
After=network.target
[Service]
Environment=MULERUN_TOKEN=mr_xxxxx
Environment=CLI2API_API_KEYS=sk-prod-key-1
Environment=CLI2API_JOBSTORE_DSN=file:/var/lib/cli2api/jobs.db
ExecStart=/usr/local/bin/cli2api
Restart=on-failure
User=cli2api
[Install]
WantedBy=multi-user.target