Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/kdpuvvadi/pocketbase

pocketbase docker container
https://github.com/kdpuvvadi/pocketbase

Last synced: 26 days ago
JSON representation

pocketbase docker container

Awesome Lists containing this project

README

        


PocketBase logo

Docker images for PocketBase



![](https://img.shields.io/github/v/release/kdpuvvadi/pocketbase?color=success&display_name=tag&label=docker&logo=docker) ![](https://img.shields.io/github/v/release/pocketbase/pocketbase?color=success&display_name=tag&label=pocketbase&logo=pocketbase)

## builds

| arch | Support |
| :----: | :-------: |
| amd64 | ✓ |
| arm64 | ✓ |
| armv7 | ✓ |

## Docs

Checkout the docs at https://pocketbase.io/docs/

## deploy

### Quick run

```shell
docker run -v ./pb_data:/usr/src/app/pb_data --name pocketbase -p 8090:8090 kdpuvvadi/pocketbase:latest
```

Pocketbase's admin UI will be avaiable at `:8090/_/` and API at `:8090/api/`

### With compose

```shell
git clone https://github.com/kdpuvvadi/pocketbase.git pocketbase
docker compose up -d
```

## Production ready setup

It is [recommended](https://pocketbase.io/docs/going-to-production/#enable-settings-encryption) to use encryption for storing settings. Generate 32 charector random string with the following

```shell
openssl rand -hex 16
```

### Docker compose with traefik reverse proxy

```yaml
services:
pocketbase:
image: ghcr.io/kdpuvvadi/pocketbase:latest
container_name: pocketbase
volumes:
- ./pb_data:/usr/src/app/pb_data
- ./pb_public:/usr/src/app/pb_public
- ./pb_hooks:/usr/src/app/pb_hooks
environment:
PB_ENCRYPTION_KEY: 32charkey # replace it with the one generated by $ openssl rand -hex 16
ports: # optional if it is running behind proxy, good for debugging & health checks
- 8090:8090
command: --encryptionEnv=PB_ENCRYPTION_KEY
labels:
- "traefik.enable=true"
- "traefik.docker.network=proxy" # replace it based on your setup
- "traefik.http.routers.pb.entrypoints=https"
- "traefik.http.routers.pb.rule=Host(`pb.example.net`)" # change it to fqdn
- "traefik.http.routers.pb.middlewares=default-headers@file"
- "traefik.http.routers.pb.tls=true"
- "traefik.http.routers.pb.service=pb"
- "traefik.http.services.pb.loadbalancer.server.scheme=http"
- "traefik.http.services.pb.loadbalancer.server.port=8090"
networks:
- proxy # replace it based on your setup
restart: unless-stopped
healthcheck:
test: curl --fail http://localhost:8090/api/health || exit 1
interval: 30s
retries: 5
start_period: 10s
timeout: 5s

networks:
proxy: # replace it based on your setup
external: true
```

## Support

If you encounter any issue with the images, feel free to reach out with issue or a PR.