Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

feat: add support for sql-based databases#2506

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
pkuwwt wants to merge17 commits intofilebrowser:master
base:master
Choose a base branch
Loading
frompkuwwt:psql

Conversation

@pkuwwt
Copy link

@pkuwwtpkuwwt commentedJun 17, 2023
edited
Loading

Description
Add sql support in addition to bolt, including sqlite3, postgres, mysql.

Most code are instorage/sql, except a few lines incmd/root.go andcmd/utils.go.

Usage

filebrowser -d sqlite3://test.dbfilebrowser -d'postgres://user:password@192.168.1.100:5432/postgres?sslmode=disable'

Reason
Bolt is a relative non-mainstream choice for storage. When someone use filebrowser as a component of a project, he/she will need a centralized storage server, e.g. postgres, mysql, other than bolt.

baur, adityathebe, yeicor, jonathanchancey, saioia-msu, sevmonster, onedr0p, and chyld reacted with thumbs up emoji
@pkuwwtpkuwwt requested a review fromo1egl as acode ownerJune 17, 2023 14:02
@github-actions
Copy link

This PR is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.

@o1eglo1egl added wip and removed Stale labelsJul 22, 2023
@o1eglo1eglforce-pushed themaster branch 2 times, most recently from813c2e9 to66dfbb3CompareJuly 28, 2023 22:27
@pkuwwt
Copy link
Author

conflicts resolved@o1egl

@sevmonster
Copy link

sevmonster commentedFeb 6, 2024
edited
Loading

Can any effort be put into merging this? Filebrowser CLI cannot be used inside container or while it's running in general, because of the exclusive database lock. This is seriously inconvenient. I am forced at this point to either kill filebrowser every time I want to run a CLI command, or build this PR for use in production. This also affects automation and makes it difficult to programmatically add users (for example) based on other input. I would use the API but it is not documented and seems fiddly to use,#2551.

FrankMormino and onedr0p reacted with thumbs up emoji

@sevmonster
Copy link

sevmonster commentedFeb 7, 2024
edited
Loading

I built this and merged withmaster. Works with Postgres, but I've found some issues.

  1. Thegithub.com/mattn/go-sqlite3 library isn't being updated anymore, and the last release is from 2022. It didn't build successfully on my machine, and I had to update it to the latest Git commitv0.0.0-20240202170028-6ee3e6746e6b to build.
  2. AuthMethod of typeproxy does not seem to work. It either isn't grabbing the header from theauther row, or is not being properly substituted in the SQL statement. I am investigating.
    The statement being run:
    SELECT id,username,password,scope,locale,lockpassword,viewmode,perm,commands,sorting,rules,hidedotfiles,dateformat,singleclickFROM"fb_users"WHERE username=''
    As a consequence of this, I see the login page since it is shown when the user either doesn't exist or isn't authed properly, as noted in many other issues.
    Actually, this seems to be an upstream bug.Proxy auth doesn't work #2995
  3. config set attempts to insert already existing rows, likeRoot andSocket. I had to delete all the offending rows to allow it to re-insert them in order to use the command and add new values.

@pkuwwt
Copy link
Author

@sevmonsterconfig set problem solved by insert-or-update

sevmonster and FrankMormino reacted with heart emoji

@hacdiashacdias removed the wip labelJun 13, 2025
@hacdiashacdias removed the request for review fromo1eglNovember 14, 2025 15:31
@hacdiashacdias changed the titlePsqlfeat: add support for sql-based databasesNov 14, 2025
@hacdias
Copy link
Member

hacdias commentedNov 14, 2025
edited
Loading

Hey! Thanks for all the effort put into this. I do agree that this could be useful, but it's quite a large change and effort to maintain. As such, I am parking this now, but leaving the PR open.

@hacdiashacdias requested a review froma teamNovember 14, 2025 16:46
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

4 participants

@pkuwwt@sevmonster@hacdias@o1egl

[8]ページ先頭

©2009-2025 Movatter.jp