Sign inSign up

5nickels/foxschema

By 5nickels

•Updated about 17 hours ago

Open-source database schema comparison and migration tool with multi-database support.

Image
Developer tools
Data science
Databases & storage
1

3.2K

5nickels/foxschema repository overview

⁠FoxSchema

FoxSchema is an open-source database schema comparison, migration, and deployment tool.

Compare a source database against a target, review schema differences, generate dialect-native migration SQL, and deploy changes from one interface.

Supports multiple SQL database engines and can run as a Docker container, CLI, desktop app, or self-hosted web application.

⁠Features

  • Compare database schemas
  • Detect tables, columns, indexes, constraints, views, and other schema changes
  • Generate database-native migration SQL
  • Review SQL before deployment
  • Execute migrations directly against the target database
  • Migration and execution history
  • Dependency-aware deployment
  • Persistent encrypted database connections
  • Multi-database support
  • Docker, npm, Homebrew, and WinGet distribution
  • Free and open source

⁠Install

⁠npm — macOS, Windows, Linux
npm install -g foxschema

Supports arm64 and x64.

⁠Homebrew — macOS
brew tap tedious-code/foxschema https://github.com/tedious-code/foxschema

brew trust tedious-code/foxschema &&
brew install foxschema
⁠WinGet — Windows
winget install OpenJS.NodeJS.LTS &&
npm install -g foxschema

⁠Docker Quick Start

No .env file is required for the default setup.

FoxSchema automatically creates an encryption key and stores application data in /data.

docker pull 5nickels/foxschema:latest

docker run -d \
  --name foxschema \
  -p 3001:3001 \
  -v foxschema_data:/data \
  5nickels/foxschema:latest

Open:

http://localhost:3001

Keep the same /data volume across container recreations and restarts. FoxSchema stores its metadata and encryption key there, allowing saved database connections to remain decryptable.

⁠Docker Images

TagDescription
latestStandard multi-architecture image supporting all available dialects

⁠Default Configuration

FoxSchema is designed to work immediately after starting the container.

  • Port: 3001
  • Authentication: Single-user mode by default
  • Metadata database: SQLite
  • Persistent storage: /data
  • Encryption: Automatic encryption key generation on first boot
  • Configuration: No .env required for the default deployment

⁠Environment Variables

VariableDefaultDescription
APP_ENCRYPTION_KEYAuto-generatedEncryption key used to protect stored connection credentials. Generate your own with openssl rand -hex 32 if required.
PORT3001Application listen port
API_PORT3001API listen port
LOCAL_SINGLE_USERtrueEnables local single-user mode
AUTH_REQUIREDfalseEnable authentication when running FoxSchema in multi-user mode
APP_DB_ENGINEsqliteMetadata database engine. Can also use postgres or mysql
APP_DB_URL—Connection URL when using PostgreSQL or MySQL as the metadata store

⁠Example: Persistent Custom Encryption Key

For production environments, you can explicitly configure an encryption key:

openssl rand -hex 32

Then start FoxSchema:

docker run -d \
  --name foxschema \
  -p 3001:3001 \
  -v foxschema_data:/data \
  -e APP_ENCRYPTION_KEY="YOUR_GENERATED_KEY" \
  5nickels/foxschema:latest

⁠Demo

See FoxSchema in action:

Connect → Compare → Review differences → Generate migration SQL → Execute → History

Video:

https://github.com/tedious-code/foxschema/raw/main/docs/demo/foxschema-demo.mp4⁠

⁠Typical Use Cases

FoxSchema is useful for:

  • Development and staging database synchronization
  • Reviewing schema changes before deployment
  • Generating migration scripts
  • Database modernization and migration projects
  • CI/CD database deployment workflows
  • Comparing environments after releases
  • Detecting schema drift
  • DBA and developer troubleshooting

⁠License

FoxSchema is free and open source under the Apache License 2.0.

https://github.com/tedious-code/foxschema/blob/main/LICENSE⁠

Tag summary

Content type

Image

Digest

sha256:1bddae67a…

Size

392.6 MB

Last updated

about 17 hours ago

docker pull 5nickels/foxschema