This NPM package provides a pre-configured Postgres setup for Docker.
This NPM package provides a pre-configured Postgres setup for Docker. It allows customization through environment variables. Follow the instructions below to integrate this package into your project.
To install the package, run the following command:
yarn add s-postgres
Create a .env
file in your project with the following example configuration:
DATABASE_URL="postgresql://username:password@localhost:5010/mydb?schema=public"
CONTAINER_NAME="s-postgres"
Adjust the values accordingly based on your requirements. If you do not add your file here, the values presented will be added automatically.
After installing the package, add the following script to your package.json
file:
"scripts": {
"start": "s-postgres"
}
Now, you can run the package by executing:
yarn start
This will initialize the Postgres container with the specified configuration.
Make sure to customize the DATABASE_URL
and CONTAINER_NAME
variables in your .env
file to match your project's needs.
Ensure that Docker is installed and running on your machine before using this package.
Feel free to reach out if you encounter any issues or have further questions.
Don't worry, with this template you will anyways get all the awesomeness you need:
- 📦 s-update-manager - Manage your dependencies with centralized repozystory
- 🎨 s-customize - Customize your repozytory with one command
- 🌐 ngrok - For local development with remote services
- ✨ ESlint and Prettier - For clean, consistent, and error-free code
- 🛠️ Extremely strict TypeScript - With
ts-reset
library for ultimate type safety - 🚀 GitHub Actions - Pre-configured actions for smooth workflows, including Bundle Size and performance stats
- Jest - For rock-solid unit and integration tests
- Smoke Testing and Acceptance Tests - For confidence in your deployments
- Conventional commits git hook - Keep your commit history neat and tidy
- Absolute imports - No more spaghetti imports
- Patch-package - Fix external dependencies without losing your mind
- Components coupling and cohesion graph - A tool for managing component relationships
- Semantic Release - for automatic changelog
- Husky - Git hooks made easy (see Git Hooks Documentation)