Skip to content

Commit 41542e5

Browse files
committed
Implement Docker support and enhance project structure
- Added .dockerignore and Dockerfile.dev for containerization. - Introduced docker-compose.dev.yml for local development setup. - Created new scripts for database initialization and role checks in the docker directory. - Updated ESLint configuration and added new ESLint config file. - Enhanced README.md with additional documentation for GitHub issues and discussions. - Refactored various components and pages to improve structure and maintainability. - Added new utility functions and hooks for better state management and API interactions.
2 parents dce6869 + e250693 commit 41542e5

203 files changed

Lines changed: 29982 additions & 8119 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.dockerignore

Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
# Dependencies
2+
node_modules
3+
npm-debug.log*
4+
yarn-debug.log*
5+
yarn-error.log*
6+
.pnpm-debug.log*
7+
8+
# Next.js
9+
.next
10+
out
11+
dist
12+
build
13+
14+
# Testing
15+
coverage
16+
.nyc_output
17+
*.test.ts
18+
*.test.tsx
19+
*.spec.ts
20+
*.spec.tsx
21+
__tests__
22+
23+
# Environment variables
24+
.env
25+
26+
# IDE
27+
.vscode
28+
.idea
29+
*.swp
30+
*.swo
31+
*~
32+
33+
# OS
34+
.DS_Store
35+
Thumbs.db
36+
37+
# Git
38+
.git
39+
.gitignore
40+
.gitattributes
41+
42+
# Documentation
43+
*.md
44+
!README.md
45+
docs
46+
47+
# Docker
48+
Dockerfile
49+
.dockerignore
50+
docker-compose*.yml
51+
52+
# CI/CD
53+
.github
54+
.vercel
55+
56+
# Misc
57+
.cache
58+
.turbo
59+
*.log
60+
tsconfig.tsbuildinfo
61+
62+
63+
64+
65+
66+
67+

.env.example

Lines changed: 44 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,44 @@
1-
DATABASE_URL=""
2-
NEXT_PUBLIC_BLOCKFROST_API_KEY_MAINNET=""
3-
NEXT_PUBLIC_BLOCKFROST_API_KEY_PREPROD=""
4-
BLOB_READ_WRITE_TOKEN=""
1+
# Environment Variables Template
2+
# Copy this file to .env.local for local development (non-Docker)
3+
# Or use .env.dev.example / .env.prod.example for Docker Compose setups
4+
5+
# Database Configuration
6+
# For local development: use localhost
7+
# For Docker Compose: use the service name (e.g., 'postgres')
8+
DATABASE_URL="postgresql://postgres:postgres@localhost:5432/multisig"
9+
DIRECT_URL="postgresql://postgres:postgres@localhost:5432/multisig"
10+
11+
# Node Environment (development, test, or production)
12+
NODE_ENV="development"
13+
14+
# JWT Secret (minimum 32 characters required)
15+
# Generate a secure secret: openssl rand -base64 32
16+
JWT_SECRET="your-jwt-secret-minimum-32-characters-long"
17+
18+
# Pinata IPFS Configuration
19+
# Get your JWT token from https://app.pinata.cloud/
20+
PINATA_JWT="your-pinata-jwt-token"
21+
22+
# GitHub Personal Access Token
23+
# Create one at https://github.com/settings/tokens
24+
# GITHUB_TOKEN="your-github-token" (Optional - for GitHub issue creation)
25+
26+
# Blockfrost API Keys
27+
# Get your API keys from https://blockfrost.io/
28+
# These are client-side variables (exposed to browser)
29+
NEXT_PUBLIC_BLOCKFROST_API_KEY_MAINNET="your-blockfrost-mainnet-api-key"
30+
NEXT_PUBLIC_BLOCKFROST_API_KEY_PREPROD="your-blockfrost-preprod-api-key"
31+
32+
# Optional: Skip environment validation during builds
33+
# Useful for Docker builds where env vars are set at runtime
34+
# SKIP_ENV_VALIDATION=true
35+
36+
# Optional: NextAuth Configuration (if using NextAuth.js)
37+
# NEXTAUTH_SECRET="your-nextauth-secret"
38+
# NEXTAUTH_URL="http://localhost:3000"
39+
40+
# Optional: Discord Integration (if using Discord features)
41+
# DISCORD_CLIENT_ID="your-discord-client-id"
42+
# DISCORD_CLIENT_SECRET="your-discord-client-secret"
43+
# DISCORD_BOT_TOKEN="your-discord-bot-token"
44+
# DISCORD_GUILD_ID="your-discord-guild-id"

.eslintrc.cjs

Lines changed: 0 additions & 60 deletions
This file was deleted.

.github/workflows/deploy-migrations.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,10 @@ jobs:
2626
run: npx prisma migrate deploy
2727
env:
2828
DATABASE_URL: ${{ secrets.DATABASE_URL }}
29+
DIRECT_URL: ${{ secrets.DIRECT_URL }}
2930

3031
- name: Verify migration status
3132
run: npx prisma migrate status
3233
env:
3334
DATABASE_URL: ${{ secrets.DATABASE_URL }}
35+
DIRECT_URL: ${{ secrets.DIRECT_URL }}

Dockerfile.dev

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
FROM node:20-alpine
2+
3+
# Install PostgreSQL client tools for health checks
4+
RUN apk add --no-cache postgresql-client
5+
6+
# Set working directory
7+
WORKDIR /app
8+
9+
# Copy package files
10+
COPY package.json package-lock.json* ./
11+
12+
# Copy Prisma schema (needed for postinstall script)
13+
COPY prisma ./prisma
14+
15+
# Install dependencies (postinstall will run prisma generate)
16+
RUN npm ci
17+
18+
# Expose port
19+
EXPOSE 3000
20+
21+
# Default command (can be overridden in docker-compose)
22+
CMD ["npm", "run", "dev"]

0 commit comments

Comments
 (0)