feat: Add Docker containerization with production-ready deployment#9
Open
p3n74 wants to merge 4 commits intousc-cisco:mainfrom
Open
feat: Add Docker containerization with production-ready deployment#9p3n74 wants to merge 4 commits intousc-cisco:mainfrom
p3n74 wants to merge 4 commits intousc-cisco:mainfrom
Conversation
- Add multi-stage Dockerfile optimized for Next.js standalone output - Include Bun runtime for database operations (sync, seed, reset) - Configure Next.js for standalone mode with proper static asset handling - Add docker-compose.yml with host network mode for external DB connectivity - Include comprehensive Docker documentation in README.md - Support for external MySQL database connections - Add .dockerignore for optimized build context - Enable database management scripts within containerized environment Technical improvements: - Next.js standalone output for minimal production image - Proper static asset serving in Docker environment - Host network mode for reliable external database connectivity - Source files included for database operations - Bun configuration for TypeScript path alias resolution
feat: Add Docker containerization with production-ready deployment
- Align port handling to use ENV PORT; map "${PORT}:${PORT}" in compose
- Switch to bridge networking with extra_hosts (host.docker.internal)
- Include .env in image and allow it in build context (.dockerignore update)
- Add Alpine build/runtime deps for native modules (node-pty, mysql2):
libc6-compat, libstdc++, musl-dev, linux-headers, python3, make, g++,
pkgconfig, ca-certificates, openssl, git, bash, curl
- Install bun and ensure proper symlinks; copy bun into runtime stage
- Use Next.js standalone output; copy src and node_modules for DB scripts
- Update db scripts to `bun build --target=node` then run with node to avoid aborts
- Use host.docker.internal for DB host; verified MariaDB connectivity
- Remove obsolete compose version field; clean up port exposure (ENV/EXPOSE)
Result: container starts on the configured PORT and `npm run db:sync` works against MariaDB.
fix: added math.h when compiling
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
feat: Add Docker containerization with production-ready deployment
Technical improvements: