https://github.com/avanov/postgres-local-management
Makefile to manage local Postgres instances (to avoid Docker)
https://github.com/avanov/postgres-local-management
Last synced: 5 months ago
JSON representation
Makefile to manage local Postgres instances (to avoid Docker)
- Host: GitHub
- URL: https://github.com/avanov/postgres-local-management
- Owner: avanov
- License: mpl-2.0
- Created: 2022-09-15T19:10:49.000Z (almost 4 years ago)
- Default Branch: master
- Last Pushed: 2023-01-03T23:05:57.000Z (over 3 years ago)
- Last Synced: 2024-10-06T06:03:57.317Z (over 1 year ago)
- Language: Makefile
- Size: 8.79 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# postgres-local-management
Makefile to manage local Postgres instances (to avoid Docker)
Usage
-----
Define `POSTGRES_LOCAL_MANAGEMENT_DIR`. Usually it's a project-local directory that's not tracked by your version control system.
For instance:
```bash
# .local/ is specified in .gitignore
export POSTGRES_LOCAL_MANAGEMENT_DIR=$(MY_PROJECT_ROOT)/.local
```
You can include this Makefile into your project's Makefile like this:
```Makefile
include $(POSTGRES_LOCAL_MANAGEMENT_REPO)/Makefile
```
Other customizable env vars
---------------------------
| Env var | Default if unset |
|----------------------------------------|------------------|
| `POSTGRES_LOCAL_MANAGEMENT_DB_HOST` | `localhost` |
| `POSTGRES_LOCAL_MANAGEMENT_DB_PORT` | `5432` |
| `POSTGRES_LOCAL_MANAGEMENT_DB_USER` | `$(USER)` |
| `POSTGRES_LOCAL_MANAGEMENT_DB_NAME` | `$(USER)` |
| `POSTGRES_LOCAL_MANAGEMENT_DB_PASS` | `$(USER)` |