Giter Site home page Giter Site logo

docs's Introduction

Preview

Build Go Report Card Documentation Version Chat IRC

filebrowser provides a file managing interface within a specified directory and it can be used to upload, delete, preview, rename and edit your files. It allows the creation of multiple users and each user can have its own directory. It can be used as a standalone app.

Demo

url: https://demo.filebrowser.org/

credentials: demo/demo

Features

Please refer to our docs at https://filebrowser.org/features

Install

For installation instructions please refer to our docs at https://filebrowser.org/installation.

Configuration

Authentication Method - You can change the way the user authenticates with the filebrowser server

Command Runner - The command runner is a feature that enables you to execute any shell command you want before or after a certain event.

Custom Branding - You can customize your File Browser installation by change its name to any other you want, by adding a global custom style sheet and by using your own logotype if you want.

Contributing

If you're interested in contributing to this project, our docs are best places to start https://filebrowser.org/contributing.

docs's People

Contributors

adrium avatar aimichal avatar dchandekstark avatar dmunozv04 avatar ediflyer avatar eine avatar filippofinke avatar gitbook-bot avatar hacdias avatar lil5 avatar o1egl avatar on4r avatar phanirithvij avatar steve2955 avatar wewe0901 avatar zachar2 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

docs's Issues

Log-Level DEBUG

Would be great to have a more detailed log-level to track user-logins and actions he performed (for security reasons).

Documentation integration

ATM we have multiple sources of documentation/information:

Since all of them can be rendered online, I think it'd be interesting to integrate all of them in a single static site and embed it in filebrowser. This would allow users to use and read the documentation of filebrowser even when offline or in isolated local networks.

Document how to run at startup / restart

Close filebrowser/filebrowser#411, filebrowser/filebrowser#418 and filebrowser/filebrowser#453.

In the issues referred above, and in the references in them, multiple alternatives are given:

It'd be interesting to have a short section in the web page (or maybe some hints spread in existing ones) to summarize the suggested alternatives. I think that the most relevant for this use case are systemd, screen/tmux and docker.

@yurividal, @xcvista would you like to contribute?

Complete docs about Authentication Provider

Hi, i'm implementing a custom autenticator that call an external service, let's say an oath2 provider.

Following de docs... https://docs.filebrowser.xyz/contributing/authentication-provider i think it missed 2 extra stepts.

3ΒΊ And this provider in the switch file.Settings.AuthMethod of cmd/config_import.go
4ΒΊ And (maybe) to in switch inside func (s authBackend) Get(t settings.AuthMethod) (auth.Auther, error) of storage/bolt/auth.go

If consider it's correct, i may PR this change.

Later, maybe generalize my provider :)

Great work with this project.

docker docs are incorrect for alpine because they mount the database at the wrong place

compare https://github.com/filebrowser/docs/blob/master/installation.md?plain=1#L65
with a few lines above.

wrong (alpine):

-v /path/filebrowser.db:/database.db \

correct (linuxserver):

-v /path/to/filebrowser.db:/database/filebrowser.db \

it's wrong, because it maps the db file to a file in the root, and when FileBrowser runs it makes a new file at /database/filebrowser.db
everything seems fine until you tear down the container and restart a new one, and all the configs are erased :-(

racing condition when using grecaptcha

I have enabled recaptcha using file browser config however, there seems to be a racing condition when loading
the captcha, as the plugin may not have been loaded form google yet. Here it is using version 2.9.0:

vue.esm.js:1897 TypeError: window.grecaptcha.render is not a function
    at o.mounted (Login.vue:44)
    at at (vue.esm.js:1863)
    at In (vue.esm.js:4222)
    at Object.insert (vue.esm.js:3148)
    at H (vue.esm.js:6351)
    at kr.__patch__ (vue.esm.js:6570)
    at kr.Pn.e._update (vue.esm.js:3948)
    at kr.r (vue.esm.js:4069)
    at ar.get (vue.esm.js:4482)
    at new ar (vue.esm.js:4471)

from code:

  mounted () {
    if (!recaptcha) return

    window.grecaptcha.render('recaptcha', {.  // <-- the issue
      sitekey: recaptchaKey
    })
  },

systemd auto-start uses different config file

My config file

`Sign up: false
Create User Dir: false
Auth method: json
Shell:

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

Server:
Log: stdout
Port: 9876
Base URL:
Root: .
Socket:
Address: 192.168.1.2
TLS Cert:
TLS Key:
Exec Enabled: false

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

Auther configuration (raw):

{
"recaptcha": null
}
`

and the results of "systemctl status filebrowser"

`● filebrowser.service - Filebrowser
Loaded: loaded (/etc/systemd/system/filebrowser.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Wed 2020-11-11 12:44:52 AWST; 6min ago
Process: 5953 ExecStart=/usr/local/bin/filebrowser -c /etc/filebrowser/ -d /etc/filebrowser/.db (code=exited, status=1/FAILURE)
Main PID: 5953 (code=exited, status=1/FAILURE)

Nov 11 12:44:52 Emby-Pi systemd[1]: Started Filebrowser.
Nov 11 12:44:52 Emby-Pi filebrowser[5953]: 2020/11/11 12:44:52 No config file used
Nov 11 12:44:52 Emby-Pi filebrowser[5953]: 2020/11/11 12:44:52 listen tcp 127.0.0.1:8080: bind: address already in use
Nov 11 12:44:52 Emby-Pi systemd[1]: filebrowser.service: Main process exited, code=exited, status=1/FAILURE
Nov 11 12:44:52 Emby-Pi systemd[1]: filebrowser.service: Failed with result 'exit-code'.
`

when manually run from the command line it works fine.

Any ideas?

Document HTTP API

The Web API is nice. It would help if this was documented so that it can be integrated into other systems. I have a distributed FS and use filemanager has the front-end for all of this.

When a user is created in our system we create one in filemanager user with a scope. So that it acts like a multi-tenant system. It's beautiful. We had to read through the web app to + code find endpoints.

Should have been documented.

Extremely slow downloads when accessing through nginx reverse proxy.

Hi Guys. I have filebrowser accessible via nginx reverse proxy as a location.
The download speeds are ridiculously slow when doing this. 4 hours to download a 2GB file. I tried a direct port forwarding to filebrowser, and it took 15 mins to download the very same file.
The problem does not seem to be the encryption layer, since i tried http over the nginx and it was also super slow.
This is my nginx location:

  location /files/ {
            proxy_http_version 1.1;
            proxy_set_header Connection "";
            proxy_pass http://10.10.10.2:8086/;
            add_header  X-Robots-Tag "noindex, nofollow, nosnippet, noarchive";
       }

Am i doing anything wrong, or is filebrowser misbehaving?

commands dont work on windows.

Usage:
filebrowser serve [flags]
filebrowser serve [command]

Aliases:
serve, server

Available Commands:
version Print the version number of File Browser

Flags:
-a, --address string Address to listen to (default is all of them)
--auth.header string The header name used for proxy authentication (default "X-Forwarded-User")
--auth.method string Switch between 'none', 'default' and 'proxy' authentication (default "default")
-b, --baseurl string Base URL
-d, --database string Database file (default "./filebrowser.db")
--defaults.allowCommands Default allow commands option for new users (default true)
--defaults.allowEdit Default allow edit option for new users (default true)
--defaults.allowNew Default allow new option for new users (default true)
--defaults.allowPublish Default allow publish option for new users (default true)
--defaults.commands string Default commands option for new users (default "git svn hg")
--defaults.locale string Default locale for new users, set it empty to enable auto detect from browser
-s, --defaults.scope string Default scope option for new users (default ".")
--defaults.viewMode string Default view mode for new users (default "mosaic")
-h, --help help for serve
-l, --log string Errors logger; can use 'stdout', 'stderr' or file (default "stdout")
-p, --port int HTTP Port (default is random)
--prefixurl string Prefix URL
--recaptcha.host string Use another host for ReCAPTCHA. recaptcha.net might be useful in China (default "https://www.google.com")
--recaptcha.key string ReCaptcha site key
--recaptcha.secret string ReCaptcha secret
--staticgen string Static Generator you want to enable
--version version for serve

Global Flags:
-c, --config string config file (defaults are './.filebrowser[ext]', '$HOME/.filebrowser[ext]' or '/etc/filebrowser/.filebrowser[ext]')

Use "filebrowser serve [command] --help" for more information about a command.

panic: unknown command "rm" for "filebrowser serve"

goroutine 1 [running]:
github.com/filebrowser/filebrowser/cli/cmd.Execute()
/src/cli/cmd/root.go:37 +0x66
main.main()
/src/cli/main.go:6 +0x27

C:\Program Files\filebrowser>./.filebrowser
'.' is not recognized as an internal or external command,
operable program or batch file.

installation not working on unix

I followed the installation guide and tried to run
filebrowser -s /path/to/my/files
and it says that the flag doesnt exist. Also, the flag is not in the doc for the CLI

SSL certificate

Is it possible to serve filebrowser using https? Where we should place the SSL certificates?

Obscure semantics of allow/disallow matching

First of all: File Browser is great! The UI feels real good and the feature set is consistent and matches my needs. πŸ‘

I've tried to control which files and directories could be accessed by a user but with the current semantics of the regular and regex matching the feature is really hard to use for advanced control.

First I had to find out that the first match starting at the end is used. So if I want to include a "everything is forbidden" this rule must come first followed by the allow rules. If I include an everything is forbidden rule, regular features not related to files stop working (for example I can't change the view/listing format).
Second it's really hard to get the rules right because only the name with a prepended slash and not the full path is matched.

It would be great if

  • matching would only apply to file-paths and can not break other features
  • matching the full path would be possible
  • the documentation would explain the matching algorithm if several rules match

Thank's a lot for the great work! I'll have to find a different way of controlling access to files but I'm still a happy user. πŸ‘

create directory event

Hello,
First, thank you so much for providing a simple and extremely useful utility. I've configured the filebrowser as a simple solution with some additional nginx/bash ways to provide access to user Home directory, so far all good. From what I see, when users create/upload file, I was able to change the ownership and permissions via the command runner

cmds add "after_upload" 'chown -R $USERNAME:$USERNAME $FILE'
cmds add "after_upload" 'chmod 600 $FILE' # The file has execute bit by default , forcing the permission change.
cmds add "after_copy" 'chown -R $USERNAME:$USERNAME $FILE'
cmds add "after_copy" 'chmod 600 $FILE'

However when we create a directory from the UI, these options do not work, is create directory a different event ? any help is much appreciated.

I'll try few other ways to see if I can change the ownership, but if there is anything the code provides like above would be great.

Document how to use reverse proxies without Prefix URL

Description
I'm using filebrowser behind an Apache2 reverse proxy. Before I used filebrowser --port 8675 --scope files/ --prefixurl=/files to run filebrowser and it worked perfectly, but after updating to the latest version, and trying to run filebrowser -p 8675 -r files/ -b /files/ it stopped working.

Expected behaviour
Filebrowser serving my files behind the Apache2 reverse proxy.

What is happening instead?
I get a 503 error "Service Unavailable. The server is temporarily unable to service your request due to maintenance downtime or capacity problems. Please try again later." for the Apache2 server.

[Docker] "No config file used"

Following the instructions at https://filebrowser.org/installation#docker , the container image seems to ignore/skip the /config/settings.json file.

Steps to reproduce:

mkdir -p $HOME/.filebrowser
touch $HOME/filebrowser.db
cat >$HOME/filebrowser/settings.json <<_EOT
{"address":"","baseURL":"","database":"/database/filebrowser.db","log":"stdout","port":80,"root":"/srv"}
_EOT
docker run -v $HOME/public:/srv \
    -v $HOME/.filebrowser/filebrowser.db:/database/filebrowser.db \
    -v $HOME/.filebrowser/settings.json:/config/settings.json \
    -e PUID=$(id -u) -e PGID=$(id -g) -p 8080:80 \
    filebrowser/filebrowser:s6

What I expected:

container starts, listens on port 80 internally but Docker exposes that as port 8080 on the host

What I saw:

The empty filebrowser.db was initialized, changing into a 64kB file so I know the container can access $HOME/.filebrowser, but:

[custom-init] No custom files found, skipping...
[ls.io-init] done.
2023/08/12 21:18:47 No config file used
2023/08/12 21:18:47 Listening on 127.0.0.1:8080

Since the console output says it's listening on port 8080 instead of 80, I tried restarting the container with -p 8080:8080 but then I get "connection reset by peer"

[Example] Filebrowser and GTK+ Broadway on Debian Buster

Just an example of how filebrowser can be extended with other tools. Here, filebrowser is added to a image based on debian:buster-slim, which already includes some CLI tools and other GTK3 compatible GUI apps.

FROM ghdl/ext:broadway

COPY filebrowser.config.yml /etc/filebrowser/.filebrowser.yml

RUN URL="$(curl -s https://api.github.com/repos/filebrowser/filebrowser/releases/latest | grep "browser_download_url.*linux-amd64.*tar.gz" | sed 's/.* "\(.*\)"/\1/g')" \
 && [ "$(echo "$URL" | cut -c1-5)" != "https" ] && URL="https://github.com/filebrowser/filebrowser/releases/download/v2.0.2/linux-amd64-filebrowser.tar.gz"; echo "URL: $URL" \
 && curl -fsSL "$URL" | tar -xvz -C /usr/local/bin filebrowser \
 && mkdir -p /var/lib/filebrowser/ \
 && filebrowser config init \
 && filebrowser users add hwd admin --commands '.*' --perm.admin

VOLUME /srv
EXPOSE 8080/tcp
CMD ["filebrowser"]

The config file is:

database: /var/lib/filebrowser/filebrowser.db
noauth: false
username: hwd
address: ""
log: stdout
port: 8080
root: /srv

Just build the container:

docker build -t ghdl/ext:gtk-ide .

And execute it:

$(commang -v winpty) docker run --rm -it -p 8080:8080 -e BROADWAY=5 -p 8085:8085 ghdl/ext:gtk-ide

Browse localhost:8080 and login with hwd (pass admin).

NOTE: Due to filebrowser/filebrowser#655, go to Settings > Global Settings and click UPDATE.

Click the Toggle shell button on the top-right corner, and execute bash -ic "gtkwave". Browse localhost:8085 to use the GUI app.


Screencast on a Win10 host:

gtk-ide

Config file settings ignored

Dear all,
for some reason, it seems that the config file settings (address, port) are ignored.
config file:

Sign up:          false
Create User Dir:  false
Auth method:      json
Shell:

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

Server:
  Log:       stdout
  Port:      8081
  Base URL:
  Root:      .
  Socket:
  Address:   192.168.0.22
  TLS Cert:
  TLS Key:

Defaults:
  Scope:      .
  Locale:     en
  View mode:  mosaic
  Commands:
  Sorting:
    By:
    Asc:  false
  Permissions:
    Admin:     false
    Execute:   true
    Create:    true
    Rename:    true
    Modify:    true
    Delete:    true
    Share:     true
    Download:  true
sudo service [email protected] status
● [email protected] - File browser: default.yaml
   Loaded: loaded (/etc/systemd/system/[email protected]; enabled; vendor preset: enabled)
   Active: active (running) since Fri 2019-10-25 05:25:51 CEST; 3h 9min ago
 Main PID: 16676 (filebrowser)
    Tasks: 7 (limit: 4496)
   CGroup: /system.slice/system-filebrowser.slice/[email protected]
           └─16676 /usr/local/sbin/filebrowser -c /etc/filebrowser/default.yaml

Oct 25 05:25:51 myserver systemd[1]: Started File browser: default.yaml.
Oct 25 05:25:51 myserver filebrowser[16676]: 2019/10/25 05:25:51 Using config file: /etc/filebrowser/default.yaml
Oct 25 05:25:51 myserver filebrowser[16676]: 2019/10/25 05:25:51 Listening on 127.0.0.1:8080

$FILE: No such file or directory

In Command runner, I need to do some actions on file after their upload, as explained in documentation, I use environment variables FILE, but I have the following error in log file

$FILE: No such file or directory

Followed by exit status 1

The docker version of the application is used

Option to allow embedded for use in nextcloud

I want to use a link to access filebrowser from my nextcloud dashboard but filebrowser does not allow embedded view, is there any hidding setting?

I am running this on a local network only and want to disable login/auth, there is some info in the docs but I can't figure out how to implement it on my docker-compose.

I added the env FB_NOAUTH=true in the docker compose file but it doesn't work.

reviews of merge the pull request of docs and organize docs issues at 2022-04

i m ready to work in docs but foudn so many issues not according to docs.. also many Pull reue3st pending to merge already aproved!

who is in charge to do this? any hint @ramiresviana ? i found you are the only active ( it seems)

pending issues now:

  • filebrowser/filebrowser#1589 must be migrated to docs repo
  • #12 produce a new entry with examples or a specific entry with reverse proxyes
  • #7 include this in a examples page of annex page with examples
  • #4 as in #41 we must provide examples for inits units.. i will provide sysvinit and openrc
  • #2 is pretty important.. was transfered here.. and i will try to make it!
  • #1 is too difficult and may take more time.. but i will provide minimal one only

rest is more complex/unrelated and some must be closed before close this one so i will maintain #40 open until resolved!

anonymous read-only, login for write

Hi, is there a way to configure filerun such that when you first go to the page it auto-login's as a guest user with read-only access, but then has an option to login as a different user?

I'm looking to replace an existing basic http file listing where anyone can go straight there and download listed files.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.