I created a database on one machine, but I am unable to access it from another machine:
[penberg@turing ~]$ turso db list
NAME LOCATIONS URL
foo arn (primary) libsql://foo-penberg.turso.io
[penberg@turing ~]$ turso db shell foo
Error: failed to connect: 401 Unauthorized
The issue is embarrassing and obvious when you think about it: the CLI uses basic authentication credentials to login. But those credentials are only ever stored on the machine that created the database.
Suggested fix: let's automatically generate a JWT for a database on every machine the CLI is installed on and use that for db shell.
I created a database on one machine, but I am unable to access it from another machine:
The issue is embarrassing and obvious when you think about it: the CLI uses basic authentication credentials to login. But those credentials are only ever stored on the machine that created the database.
Suggested fix: let's automatically generate a JWT for a database on every machine the CLI is installed on and use that for
db shell
.