Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
6fe4a14
feat: add production docker-compose setup for self-hosting
tyecode May 16, 2026
5080977
chore: standardize self-hosting setup for one-command deploy
tyecode May 16, 2026
ee4f92b
feat(sdk): v0.5.0 with 10 new methods, error classes, and constants
tyecode May 16, 2026
ce142a7
feat(dashboard): add analytics page with charts and sidebar integration
tyecode May 16, 2026
ecfb010
feat(api): webhook delivery logs with tracking and dashboard UI
tyecode May 16, 2026
7852a80
ci: add GitHub Actions workflows and automation
tyecode May 16, 2026
29f87c3
docs: comprehensive documentation overhaul
tyecode May 16, 2026
2801774
build: monorepo env sharing and test infrastructure
tyecode May 16, 2026
8401d7a
fix(docker): api build and production deployment fixes
tyecode May 16, 2026
adf3fc8
fix(ci): resolve pnpm version conflict and docker build context
tyecode May 16, 2026
4fedba0
fix(docker): update lockfile and build workspace dependencies before api
tyecode May 16, 2026
120512a
fix(ci): escape quotes in terms page and build workspace packages bef…
tyecode May 16, 2026
fd750b7
chore(release): v0.5.0
tyecode May 16, 2026
b3a9974
fix(docker): add buildx setup for cache support
tyecode May 16, 2026
f41fe00
fix(docker): use docker-container driver for buildx
tyecode May 16, 2026
1aaef14
ci: use conventional commit parser for release notes
tyecode May 16, 2026
567017a
fix(ci): fetch all tags for release notes generation
tyecode May 16, 2026
284ff86
ci(deps): bump softprops/action-gh-release from 2 to 3 (#2)
dependabot[bot] May 16, 2026
0895200
ci(deps): bump docker/login-action from 3 to 4 (#3)
dependabot[bot] May 16, 2026
6d2b632
ci(deps): bump docker/metadata-action from 5 to 6 (#4)
dependabot[bot] May 16, 2026
8011a60
ci(deps): bump pnpm/action-setup from 3 to 6 (#5)
dependabot[bot] May 16, 2026
c18fba9
ci(deps): bump actions/setup-node from 4 to 6 (#6)
dependabot[bot] May 16, 2026
27db376
chore(deps): disable dependabot grouping, change to monthly updates
tyecode May 16, 2026
84f9603
ci(deps): bump actions/checkout from 4 to 6
dependabot[bot] May 16, 2026
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
16 changes: 16 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
node_modules
.git
.next
dist
.turbo
.env
.env.development
.env.production
*.md
!README.md
.github
.husky
.vscode
.agents
.scripts
docs
65 changes: 65 additions & 0 deletions .env.production
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
# ══════════════════════════════════════════════
# KnotEngine — Production Environment
# ══════════════════════════════════════════════
# Copy this file to .env and replace all placeholder values
# cp .env.production .env
# ══════════════════════════════════════════════

# ── Database (Docker MongoDB) ──
MONGO_USER=knotadmin
MONGO_PASSWORD=<generate-a-strong-password>

# ── Redis (Docker Redis) ──
REDIS_PASSWORD=<generate-a-strong-password>

# ── Service URLs ──
PORT=5050
PUBLIC_URL=https://api.yourdomain.com
DASHBOARD_URL=https://dashboard.yourdomain.com
NEXT_PUBLIC_CHECKOUT_URL=https://checkout.yourdomain.com
CHECKOUT_BASE_URL=https://checkout.yourdomain.com

# ── Security & Secrets ──
# Generate with: openssl rand -hex 32
JWT_SECRET=<generate-a-random-secret>
WEBHOOK_SECRET=<generate-a-random-secret>
INTERNAL_SECRET=knot_internal_<generate-a-random-secret>
NEXTAUTH_SECRET=knot_secret_<generate-a-random-secret>
NEXTAUTH_URL=https://dashboard.yourdomain.com

# ── Blockchain Configuration ──
BITCOIN_NETWORK=bitcoin
TATUM_API_KEY=<your-tatum-api-key>
TATUM_WEBHOOK_SECRET=<your-tatum-webhook-secret>

# ── Alchemy (EVM Failover) ──
ALCHEMY_API_KEY=<your-alchemy-api-key>
ALCHEMY_AUTH_TOKEN=<your-alchemy-auth-token>
ALCHEMY_NOTIFY_WEBHOOK_ID=<your-alchemy-webhook-id>
ALCHEMY_WEBHOOK_SIGNING_KEY=<your-alchemy-signing-key>

# ── Business Logic ──
PLATFORM_FEE_RATE=0.01
MIN_INVOICE_AMOUNT=1.00
MIN_FEE_USD=0.05
WELCOME_CREDIT_AMOUNT=5.00
AFFILIATE_SIGNUP_BONUS=5.00

# ── Platform Collection Wallets ──
PLATFORM_FEE_WALLET_BTC=<your-btc-wallet-address>
PLATFORM_FEE_WALLET_LTC=<your-ltc-wallet-address>
PLATFORM_FEE_WALLET_EVM=<your-evm-wallet-address>

# ── Email Configuration ──
# Option 1: Gmail SMTP (for testing)
GMAIL_USER=<your-email@gmail.com>
GMAIL_APP_PASSWORD=<your-app-password>
FROM_EMAIL=KnotEngine <your-email@gmail.com>

# Option 2: Resend (for production)
RESEND_API_KEY=re_<your-resend-api-key>

# ── Media Storage (Optional) ──
CLOUDINARY_CLOUD_NAME=
CLOUDINARY_API_KEY=
CLOUDINARY_API_SECRET=
38 changes: 38 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
---
name: Bug Report
about: Report a bug in KnotEngine
title: "[Bug] "
labels: bug
assignees: ""
---

## Describe the Bug

A clear and concise description of what the bug is.

## To Reproduce

Steps to reproduce the behavior:

1. Go to '...'
2. Click on '...'
3. See error

## Expected Behavior

A clear and concise description of what you expected to happen.

## Screenshots

If applicable, add screenshots to help explain your problem.

## Environment

- **OS:** [e.g. macOS, Linux, Windows]
- **Node.js:** [e.g. 20.x]
- **KnotEngine Version:** [e.g. v0.5.0]
- **Deployment:** [e.g. Docker, Self-hosted, Local]

## Additional Context

Add any other context about the problem here.
29 changes: 29 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
---
name: Feature Request
about: Suggest an idea for KnotEngine
title: "[Feature] "
labels: enhancement
assignees: ""
---

## Is your feature request related to a problem?

A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

## Describe the solution you'd like

A clear and concise description of what you want to happen.

## Describe alternatives you've considered

A clear and concise description of any alternative solutions or features you've considered.

## Additional Context

Add any other context or screenshots about the feature request here.

## Priority

- [ ] Low — Nice to have
- [ ] Medium — Would improve workflow
- [ ] High — Blocking my use case
45 changes: 45 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
version: 2
updates:
- package-ecosystem: "npm"
directory: "/"
schedule:
interval: "monthly"
open-pull-requests-limit: 5
commit-message:
prefix: "chore"
include: "scope"
ignore:
- dependency-name: "node"
update-types: ["version-update:semver-major"]

- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
commit-message:
prefix: "ci"
include: "scope"

- package-ecosystem: "docker"
directory: "/apps/api"
schedule:
interval: "weekly"
commit-message:
prefix: "chore"
include: "scope"

- package-ecosystem: "docker"
directory: "/apps/dashboard"
schedule:
interval: "weekly"
commit-message:
prefix: "chore"
include: "scope"

- package-ecosystem: "docker"
directory: "/apps/checkout"
schedule:
interval: "weekly"
commit-message:
prefix: "chore"
include: "scope"
35 changes: 35 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
## Description

Brief description of the changes.

## Type of Change

- [ ] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
- [ ] Documentation update
- [ ] Refactor (no functional changes)
- [ ] CI/CD or build changes

## Testing

- [ ] I have added tests that prove my fix is effective or that my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] I have run `pnpm build` successfully
- [ ] I have run `pnpm test` successfully

## Checklist

- [ ] My code follows the project's code style
- [ ] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have updated the documentation if needed
- [ ] My changes generate no new warnings

## Screenshots (if applicable)

Add screenshots to help explain your changes.

## Related Issues

Closes #
84 changes: 84 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
name: CI

on:
push:
branches: [main]
pull_request:
branches: [main]

jobs:
lint:
name: Lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6

- uses: pnpm/action-setup@v6

- uses: actions/setup-node@v6
with:
node-version: 20
cache: "pnpm"

- run: pnpm install --frozen-lockfile

- run: pnpm lint

typecheck:
name: Type Check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6

- uses: pnpm/action-setup@v6

- uses: actions/setup-node@v6
with:
node-version: 20
cache: "pnpm"

- run: pnpm install --frozen-lockfile

- run: pnpm build

test:
name: Test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6

- uses: pnpm/action-setup@v6

- uses: actions/setup-node@v6
with:
node-version: 20
cache: "pnpm"

- run: pnpm install --frozen-lockfile

- name: Run SDK tests
run: pnpm --filter @qodinger/knot-sdk test

- name: Build workspace packages
run: pnpm --filter @qodinger/knot-types build && pnpm --filter @qodinger/knot-crypto build && pnpm --filter @qodinger/knot-database build

- name: Run API tests
run: pnpm --filter api test

- name: Run Crypto tests
run: pnpm --filter @qodinger/knot-crypto test

docker-build:
name: Docker Build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6

- name: Build API Docker image
run: docker build -t knot-api -f apps/api/Dockerfile .

- name: Build Dashboard Docker image
run: docker build -t knot-dashboard -f apps/dashboard/Dockerfile .

- name: Build Checkout Docker image
run: docker build -t knot-checkout -f apps/checkout/Dockerfile .
56 changes: 56 additions & 0 deletions .github/workflows/docker-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
name: Docker Publish

on:
push:
tags:
- "v*"
workflow_dispatch:

env:
REGISTRY: ghcr.io
IMAGE_BASE: ${{ github.repository }}

jobs:
build-and-push:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
strategy:
matrix:
service: [api, dashboard, checkout]
steps:
- uses: actions/checkout@v6

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
with:
driver: docker-container

- name: Log in to GHCR
uses: docker/login-action@v4
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Extract metadata
id: meta
uses: docker/metadata-action@v6
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_BASE }}-${{ matrix.service }}
tags: |
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
type=raw,value=latest,enable=${{ !contains(github.ref, '-') }}

- name: Build and push
uses: docker/build-push-action@v5
with:
context: .
file: ./apps/${{ matrix.service }}/Dockerfile
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
cache-from: type=gha
cache-to: type=gha,mode=max
Loading
Loading