Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions .github/workflows/staging.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Staging Deployment
on:
push:
branches:
- staging
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
- run: |
cd listener
npm ci
npm run build
- run: |
cd dashboard
npm ci
npm run build
- run: |
bash scripts/health-check.sh http://localhost:3000/health
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -475,3 +475,9 @@ This project is licensed under the MIT License.
NotifyChain is built to simplify event-driven blockchain development by bridging smart contract events with off-chain automation and notification systems.

Built on [Stellar](https://www.stellar.org/) and [Soroban](https://soroban.stellar.org/).

## Staging Environment Instructions
To run the staging environment locally:
1. Export environment variables: `export $(cat listener/.env.staging | xargs)`
2. Build and run listener: `cd listener && npm ci && npm run build && npm start`
3. Run health check: `./scripts/health-check.sh`
2 changes: 2 additions & 0 deletions dashboard/.env.staging
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
VITE_API_URL=http://localhost:3000
VITE_ENV=staging
4 changes: 4 additions & 0 deletions listener/.env.staging
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
PORT=3000
NODE_ENV=staging
STELLAR_NETWORK=testnet
RPC_URL=https://soroban-testnet.stellar.org
8 changes: 8 additions & 0 deletions scripts/health-check.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#!/bin/bash
TARGET_URL=${1:-"http://localhost:3000/health"}
STATUS=$(curl -s -o /dev/null -w "%{http_code}" "$TARGET_URL")
if [ "$STATUS" -eq 200 ]; then
exit 0
else
exit 1
fi
Loading