https://github.com/nana4rider/deploy-webhook
デプロイスクリプトを実行するためのAPI
https://github.com/nana4rider/deploy-webhook
deploy-tool webhook
Last synced: 27 days ago
JSON representation
デプロイスクリプトを実行するためのAPI
- Host: GitHub
- URL: https://github.com/nana4rider/deploy-webhook
- Owner: nana4rider
- License: isc
- Created: 2025-01-06T03:32:02.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2026-02-21T03:55:48.000Z (4 months ago)
- Last Synced: 2026-02-21T09:44:49.982Z (4 months ago)
- Topics: deploy-tool, webhook
- Language: TypeScript
- Homepage:
- Size: 733 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Deploy Webhook
[](LICENSE)


## 概要
[GitHub Actions](https://docs.github.com/ja/actions)からデプロイスクリプトを実行するためのAPIです。
## 使い方
### Native
```sh
npm install
npm run build
node --env-file=.env dist/index
```
### Docker
```sh
docker run -d \
--name deploy-webhook \
--env-file .env \
-p 3000:3000 \
-v ./deploy.sh:/app/deploy.sh
--restart always \
ghcr.io/nana4rider/deploy-webhook:latest
```
> [!TIP]
> 必要な環境変数については[こちら](src/env.ts)をご確認ください。
### GitHub Actions側の実装
```sh
TIMESTAMP=$(date +%s)
SIGNATURE=$(echo -n "$TIMESTAMP" | openssl dgst -sha256 -hmac "$WEBHOOK_SECRET" | awk '{print $2}')
curl -f -X POST "https://deploy-webhook/webhook" \
-H "X-Signature: $SIGNATURE" \
-H "X-Timestamp: $TIMESTAMP"
```
## ドキュメント
- [API Document](https://nana4rider.github.io/openapi-ui/?deploy-webhook)