flat-rose-25983
12/07/2023, 3:10 PMStarting PostgreSQL **
2023-12-07 14:56:37.602 GMT [1] LOG: pgaudit extension initialized
2023-12-07 14:56:37.610 GMT [1] LOG: starting PostgreSQL 14.4 on x86_64-pc-linux-gnu, compiled by gcc (Debian 10.2.1-6) 10.2.1 20210110, 64-bit
2023-12-07 14:56:37.610 GMT [1] LOG: listening on IPv4 address "0.0.0.0", port 5432
2023-12-07 14:56:37.610 GMT [1] LOG: listening on IPv6 address "::", port 5432
2023-12-07 14:56:37.619 GMT [1] LOG: listening on Unix socket "/tmp/.s.PGSQL.5432"
2023-12-07 14:56:37.625 GMT [131] LOG: database system was shut down at 2023-12-07 14:56:37 GMT
2023-12-07 14:56:37.634 GMT [1] LOG: database system is ready to accept connections
2023-12-07 14:56:46.323 GMT [145] FATAL: database "identity" does not exist
2023-12-07 14:56:46.556 GMT [146] FATAL: database "identity" does not exist
2023-12-07 14:56:55.601 GMT [154] FATAL: database "identity" does not exist
2023-12-07 14:56:56.104 GMT [155] FATAL: database "identity" does not exist
2023-12-07 14:57:17.114 GMT [184] FATAL: database "identity" does not exist
Kratos logs:
kubectl logs kratos-86f7b57998-fxwwx -c kratos-automigrate -n auth-default
time=2023-12-07T15:06:57Z level=info msg=No tracer configured - skipping tracing setup audience=application service_name=Ory Kratos service_version=v1.0.0
time=2023-12-07T15:06:57Z level=debug msg=Connecting to SQL Database audience=application connMaxLifetime=0s idlePool=2 pool=4 service_name=Ory Kratos service_version=v1.0.0
time=2023-12-07T15:06:58Z level=warning msg=Unable to ping database, retrying. audience=application error=map[message:failed to connect to `host=postgres user=postgres database=identity`: server error (FATAL: database "identity" does not exist (SQLSTATE 3D000)) stack_trace:
<http://github.com/ory/kratos/persistence/sql.(*Persister).Ping|github.com/ory/kratos/persistence/sql.(*Persister).Ping>
astonishing-morning-18498
12/07/2023, 8:50 PMbland-eye-99092
12/10/2023, 7:07 PMmigrate
command. See here for a configuration using docker compose: https://github.com/ory/kratos/blob/master/quickstart.yml#L3-L18flat-rose-25983
12/11/2023, 7:39 PMkratos:
fullnameOverride: 'kratos'
image:
repository: 'oryd/kratos'
tag: 'v1.0.0' # Don't forget to update init container below
deployment:
annotations:
rollme: '{{ randAlphaNum 5 | quote }}'
extraVolumes:
- name: oic-config
configMap:
name: kratos-oic-config
extraVolumeMounts:
- name: oic-config
mountPath: /etc/config/kratos/oic-configuration
readOnly: true
livenessProbe:
initialDelaySeconds: 5
periodSeconds: 10
failureThreshold: 5
readinessProbe:
initialDelaySeconds: 5
periodSeconds: 10
failureThreshold: 5
startupProbe:
failureThreshold: 60
successThreshold: 1
periodSeconds: 1
timeoutSeconds: 1
kratos:
autoMigrate: false
development: false
emailTemplates:
recovery:
valid:
subject: Recover access to your account
body: |-
Hi, please recover access to your account by clicking the following link:
<a href="{{ .RecoveryURL }}">{{ .RecoveryURL }}</a>
plainBody: |-
Hi, please recover access to your account by clicking the following link: {{ .RecoveryURL }}
invalid:
subject: Account access attempted
body: |-
Hi, you (or someone else) entered this email address when trying to recover access to an account.
However, this email address is not on our database of registered users and therefore the attempt has failed. If this was you, check if you signed up using a different address. If this was not you, please ignore this email.
plainBody: |-
Hi, you (or someone else) entered this email address when trying to recover access to an account.
verification:
valid:
subject: Please verify your email address
body: |-
Hi, please verify your account by clicking the following link:
<a href="{{ .VerificationURL }}">{{ .VerificationURL }}</a>
plainBody: |-
Hi, please verify your account by clicking the following link: {{ .VerificationURL }}
invalid:
subject: Please verify your email address
body: |-
Hi, you (or someone else) entered this email address when trying to recover access to an account.
However, this email address is not on our database of registered users and therefore the attempt has failed. If this was you, check if you signed up using a different address. If this was not you, please ignore this email.
plainBody: |-
Hi, you (or someone else) entered this email address when trying to recover access to an account.
config:
flat-rose-25983
12/11/2023, 8:00 PMkratos migrate sql
How do i run this automaticallybland-eye-99092
12/12/2023, 9:17 AMI have to run each timeYou could use a job for thatHow do i run this automaticallykratos migrate sql
flat-rose-25983
12/13/2023, 7:26 AMextraInitContainers: |
- name: automigrate-init
image: oryd/kratos:v0.10.1
command: ["kratos"]
args: ["migrate", "sql", "-e", "--yes"]
env:
- name: DSN
valueFrom:
secretKeyRef:
key: dsn
name: kratos
bland-eye-99092
12/13/2023, 8:35 AMastonishing-morning-18498
12/16/2023, 6:15 PMflat-rose-25983
12/17/2023, 2:50 PMastonishing-morning-18498
12/17/2023, 4:05 PM