I tried to reinitialise our spicedb
# spicedb
v
for testing purposes we recommend using
spicedb serve-testing
which creates isolated development environments, isolated by client-provided preshared key. We do not recommend messing with the tables directly, as things like this can happen. It's not as simple as running "TRUNCATE".
c
yes, but how can i restart the service?
at first we tried to edit schema
and we cant
so we drop the table
y
you'd need to start with a clean database and run
spicedb migrate HEAD
c
that exactly what i did
[root@SRV-DEV-SPICEDB log]# spicedb migrate head --datastore-engine postgres --datastore-conn-uri postgresql://svc-spicedb:passowrd@srv-sql:5432/spicedb
3:09PM ERR terminated with errors error="unable to migrate to
head
revision: error executing migration `1eaeba4b8a73`: ERROR: no schema has been selected to create in (SQLSTATE 3F000)"
i also use ALTER DATABASE spicedb SET search_path TO public; on pgsql
2024-06-25 15:19:28 CEST [108540]: user=svc-spicedb,db=spicedb,app=[unknown],client=SRV-DEV-SPICEDB.altima.local LOG: statement: CREATE TABLE relation_tuple_transaction ( 2024-06-25 15:19:28 CEST [108540]: user=svc-spicedb,db=spicedb,app=[unknown],client=SRV-DEV-SPICEDB.altima.local ERROR: no schema has been selected to create in at character 14 2024-06-25 15:19:28 CEST [108540]: user=svc-spicedb,db=spicedb,app=[unknown],client=SRV-DEV-SPICEDB.altima.local STATEMENT: CREATE TABLE relation_tuple_transaction ( 2024-06-25 15:19:28 CEST [108540]: user=svc-spicedb,db=spicedb,app=[unknown],client=SRV-DEV-SPICEDB.altima.local LOG: disconnection: session time: 0:00:00.010 user=svc-spicedb database=spicedb host=SRV-DEV-SPICEDB.altima.local port=37224
v
you'd have drop all tables and run
spicedb migrate HEAD
40 Views