datasette / datasette-write-ui

A Datasette plugin that adds UI elements to edit, insert, or delete rows in SQLite tables
Apache License 2.0
15 stars 2 forks source link

"Attempt to write a readonly database" as root actor, with ACL permissions to database #22

Open voltagex opened 5 months ago

voltagex commented 5 months ago

datasette, version 1.0a7

attempt to write a readonly database
INFO:     [myip]:52691 - "POST /[mydb]/records/7/-/delete HTTP/1.1" 500 Internal Server Error
getfacl /var/lib/db/mydb.db
getfacl: Removing leading '/' from absolute path names
# file: var/lib/db/mydb.db
# owner: root
# group: root
user::rw-
user:voltagex:rwx
group::r--
mask::rwx
other::r--

If I run datasette as the root user then it works, but I would rather not do this.

touch /var/lib/db/mydb.db is working logged into the system as my normal user account, so I am not sure what is setting the database as read only.