Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DietPi-Software | File Browser #4686

Merged
merged 9 commits into from
Sep 15, 2021
Merged

DietPi-Software | File Browser #4686

merged 9 commits into from
Sep 15, 2021

Conversation

Joulinar
Copy link
Collaborator

@Joulinar Joulinar commented Aug 24, 2021

DietPi-Software | filebrowser - new software title, ID 198

Status: ready

  • add new software title filebrowser
  • perform testing (RPi1, RPi3B+, RPi4B, VM)

Reference: #2560

Commit list/description:

  • DietPi-Software | filebrowser - initial setup, add new software title, reserve ID 198
  • DietPi-Software | filebrowser - add install and uninstall

@Joulinar Joulinar added this to the v7.6 milestone Aug 24, 2021
@Joulinar Joulinar self-assigned this Aug 24, 2021
@Joulinar Joulinar marked this pull request as draft August 24, 2021 10:20
@Joulinar Joulinar linked an issue Aug 24, 2021 that may be closed by this pull request
@Joulinar
Copy link
Collaborator Author

Joulinar commented Aug 24, 2021

@MichaIng

couple of questions I have:

  • executable location /opt/filebrowser/
  • config file location /mnt/dietpi_userdata/filebrowser/
  • user home /mnt/dietpi_userdata/filebrowser/
  • add user filebrowser to group dietpi
  • service executed as user filebrowser
  • service executed as group dietpi
  • should we lock File Browser to a specific directory like /mnt/ or give full access
  • default user to login root, dietpi or filebrowser
  • port to be used 8085

At the moment I'm not happy how service is stopped. It looks more like a failure, than stopping a service.

Aug 24 22:29:04 DietPi3 systemd[1]: Stopping File Browser (DietPi)...
Aug 24 22:29:04 DietPi3 systemd[1]: filebrowser.service: Main process exited, code=exited, status=1/FAILURE
Aug 24 22:29:04 DietPi3 systemd[1]: filebrowser.service: Failed with result 'exit-code'.
Aug 24 22:29:04 DietPi3 systemd[1]: Stopped File Browser (DietPi).

@MichaIng
Copy link
Owner

As we discussed, agreed with all your suggestions above. Not sure about the default login user name, as we have no consistent one for other web interfaces either, sometimes root, sometimes admin, sometimes dietpi...

Probably using dietpi fits best, also to align other software with, so that it is not the number 1-5 attempt of a brute-force attack, but still a shared username for every software/web interface?

@Joulinar
Copy link
Collaborator Author

ok let's go with user dietpi. We could add on or docs how to add new users if needed.

@Joulinar
Copy link
Collaborator Author

Joulinar commented Sep 1, 2021

ok from my side testing is done, I checked installation on all my platforms (RPi1, RPi3B+, RPi4B, VM). Ready for review from my end.

dietpi/dietpi-software Outdated Show resolved Hide resolved
@MichaIng
Copy link
Owner

So if I understand it right, v1.x used a config file while v2.x uses a database only: https://filebrowser.org/upgrade-from-1.x
And the -c option is then used to migrate an old config or import one (as a convenience feature so it can be pre-configured via text editor): https://filebrowser.org/cli/filebrowser-config-import

Since we can use the CLI to create and configure the database directly, no need for this. What we may add in the future, is to allow users placing a custom config file and importing it automatically at install.

dietpi/dietpi-software Outdated Show resolved Hide resolved
dietpi/dietpi-software Outdated Show resolved Hide resolved
dietpi/dietpi-software Outdated Show resolved Hide resolved
dietpi/dietpi-software Outdated Show resolved Hide resolved
@Joulinar
Copy link
Collaborator Author

ok will have a look tomorrow during the day on the changes you requested.

@Joulinar
Copy link
Collaborator Author

Joulinar commented Sep 15, 2021

Ok I did the adjustments and removed the temp code. One thing I'm not sure with are the file and/or directory permissions if created by filebrowser. Everything will be created with 775 permissions.

dietpi/dietpi-software Outdated Show resolved Hide resolved
DietPi-Software | filebrowser - initial setup, add new software title, reserve ID 198
DietPi-Software | filebrowser - add install and uninstall
DietPi-Survey_Report | filebrowser - add new software title
DietPi-Software | | filebrowser - further adjustments
+ CHANGELOG | File Browser: Access and manage your data von anywhere via browser with this lightweight remote file manager. Other than ownCloud and Nextcloud, it accesses the raw data on your filesystem, based on a chosen root directory, which makes it similar to Syncthing. But no native file sharing feature are included, though you can setup multiple users with their own root directory.
+ CHANGELOG | Typo
+ DietPi-Software | File Browser: Move install definition and docs URL according to changed category
+ DietPi-Software | File Browser: Do not add the user to www-data group
+ DietPi-Software | File Browser: Do not actively make the File Browser config and install dir R/W accessible to "dietpi" group
+ DietPi-Software | File Browser: Add official docs to systemd unit
@MichaIng
Copy link
Owner

MichaIng commented Sep 15, 2021

Hah, it DOES have a sharing feature, right below the rename button. Makes the file(s) available via password-protected link for a defined time range. How could I have overseen that earlier 😄.

But the most important question these days: Where is the dark mode? 🤣
Database is only accessible when the service has been stopped, else it shows "timeout" 🤔. But then:

/mnt/dietpi_userdata/filebrowser# /opt/filebrowser/filebrowser config cat
Sign up:          false
Create User Dir:  false
Auth method:      json
Shell:

Branding:
  Name:
  Files override:
  Disable external links:  false

Server:
  Log:           stdout
  Port:          8085
  Base URL:
  Root:          /mnt
  Socket:
  Address:       0.0.0.0
  TLS Cert:
  TLS Key:
  Exec Enabled:  false

Defaults:
  Scope:         .
  Locale:        en
  View mode:     list
  Single Click:  false
  Commands:
  Sorting:
    By:   name
    Asc:  false
  Permissions:
    Admin:     false
    Execute:   true
    Create:    true
    Rename:    true
    Modify:    true
    Delete:    true
    Share:     true
    Download:  true

Auther configuration (raw):

{
  "recaptcha": null
}

No dark mode, but good to see what's possible.

I'm impressed, I have to say. Many important features are there, even a command line, showing file hashes and such, but all well placed, looks clean and sorted.

+ CHANGELOG | File Browser: Fix info about sharing abilities
@MichaIng
Copy link
Owner

Ready from my end 👍.

@Joulinar
Copy link
Collaborator Author

Feel free to move into dev. Will have a look later the evening and create docs tomorrow.

@MichaIng MichaIng merged commit f8ba845 into dev Sep 15, 2021
@MichaIng MichaIng deleted the filebrowser branch September 15, 2021 15:59
@MichaIng MichaIng changed the title DietPi-Software | filebrowser DietPi-Software | File Browser Sep 16, 2021
@Joulinar
Copy link
Collaborator Author

No dark mode, but good to see what's possible.

BTW it is supporting dark mode. Available setting on admin panel

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

DietPi-Software | File Browser
2 participants