Files
postgres/README.md
T

80 lines
1.9 KiB
Markdown
Raw Normal View History

2023-09-02 21:31:55 -04:00
## 👋 Welcome to postgres 🚀
postgres README
## Install my system scripts
```shell
sudo bash -c "$(curl -q -LSsf "https://github.com/systemmgr/installer/raw/main/install.sh")"
sudo systemmgr --config && sudo systemmgr install scripts
```
## Automatic install/update
```shell
dockermgr update postgres
```
## Install and run container
```shell
2026-05-12 20:08:20 -04:00
dockerHome="/var/lib/srv/$USER/docker/casjaysdevdocker/postgres/postgres/latest/rootfs"
mkdir -p "/var/lib/srv/$USER/docker/postgres/rootfs"
2023-09-02 21:31:55 -04:00
git clone "https://github.com/dockermgr/postgres" "$HOME/.local/share/CasjaysDev/dockermgr/postgres"
2026-05-12 20:08:20 -04:00
cp -Rfva "$HOME/.local/share/CasjaysDev/dockermgr/postgres/rootfs/." "$dockerHome/"
2023-09-02 21:31:55 -04:00
docker run -d \
--restart always \
--privileged \
2026-05-12 20:08:20 -04:00
--name casjaysdevdocker-postgres-latest \
2023-09-02 21:31:55 -04:00
--hostname postgres \
-e TZ=${TIMEZONE:-America/New_York} \
2026-05-12 20:08:20 -04:00
-v "$dockerHome/data:/data:z" \
-v "$dockerHome/config:/config:z" \
2023-09-02 21:31:55 -04:00
-p 80:80 \
casjaysdevdocker/postgres:latest
```
## via docker-compose
```yaml
version: "2"
services:
ProjectName:
image: casjaysdevdocker/postgres
container_name: casjaysdevdocker-postgres
environment:
- TZ=America/New_York
- HOSTNAME=postgres
volumes:
2026-05-12 20:08:20 -04:00
- "/var/lib/srv/$USER/docker/casjaysdevdocker/postgres/postgres/latest/rootfs/data:/data:z"
- "/var/lib/srv/$USER/docker/casjaysdevdocker/postgres/postgres/latest/rootfs/config:/config:z"
2023-09-02 21:31:55 -04:00
ports:
- 80:80
restart: always
```
## Get source files
```shell
dockermgr download src casjaysdevdocker/postgres
```
OR
```shell
git clone "https://github.com/casjaysdevdocker/postgres" "$HOME/Projects/github/casjaysdevdocker/postgres"
```
## Build container
```shell
cd "$HOME/Projects/github/casjaysdevdocker/postgres"
buildx
```
## Authors
🤖 casjay: [Github](https://github.com/casjay) 🤖
⛵ casjaysdevdocker: [Github](https://github.com/casjaysdevdocker) [Docker](https://hub.docker.com/u/casjaysdevdocker) ⛵