icicimov / kubernetes-bitwarden_rs

Kubernetes manifests for the bitwarden_rs project https://github.com/dani-garcia/bitwarden_rs.git
Apache License 2.0
49 stars 39 forks source link

need to connect remote database #12

Open sohag033 opened 2 years ago

sohag033 commented 2 years ago

Hi, I want to connect the remote database with PGSQL. I have already tried with just docker with below cmd and its working fine docker run -d --name vaultwarden -e DATABASE_URL=postgresql://vaultwarden:password@db host:5432/vaultwarden -p 80:80 vaultwarden/server:latest

But in K8s I am trying to connect to the remote host with the below configmap. why it's not connected?

apiVersion: v1 kind: ConfigMap metadata: name: vaultwarden-configmap namespace: sohag data: DATABASE_CONNECTION: "postgresql" DATABASE_URL: "host.rds.com:5432" POSTGRES_USER: "vaultwarden" POSTGRES_PASSWORD: "Password" POSTGRES_DB: "vaultwarden"

could you please help me to solve the problem? BR, Samajpati

icicimov commented 2 years ago

So why don't you put the same:

DATABASE_URL: "postgresql://vaultwarden:password@db host:5432/vaultwarden"

in the configmap?