From e9f146a0a2317a3078def903f73194d84c2399e1 Mon Sep 17 00:00:00 2001 From: blek Date: Sat, 21 Oct 2023 01:23:22 +1000 Subject: [PATCH] add config --- docker-compose.dev.yml | 1 + filed/config/.gitignore | 1 + filed/config/filed.toml.example | 46 +++++++++++++++++++++++++++++++++ 3 files changed, 48 insertions(+) create mode 100644 filed/config/.gitignore create mode 100644 filed/config/filed.toml.example diff --git a/docker-compose.dev.yml b/docker-compose.dev.yml index ce00844..8915d1b 100644 --- a/docker-compose.dev.yml +++ b/docker-compose.dev.yml @@ -8,6 +8,7 @@ services: bfile: volumes: - './filed:/opt/code' + - './filed/config:/etc/filed' - '/opt/code/target' - './volatile/files:/opt/user_uploads' janitord: diff --git a/filed/config/.gitignore b/filed/config/.gitignore new file mode 100644 index 0000000..a5ef6e7 --- /dev/null +++ b/filed/config/.gitignore @@ -0,0 +1 @@ +filed.toml diff --git a/filed/config/filed.toml.example b/filed/config/filed.toml.example new file mode 100644 index 0000000..3759d7f --- /dev/null +++ b/filed/config/filed.toml.example @@ -0,0 +1,46 @@ +# Welcome to the filed main configuration file! +# The comments in this file will be your guide to configuring it to fit your needs. + +# If you wish there were an option in this file, +# open an issue or a PR at the git repo: +# https://git.blek.codes/blek/bfile + +[files] + +# Allow uploads to this server. +# Its useful to turn it off during attacks +allow_uploads=true + +# Allow custom names for files +allow_custom_names=true + +# Allow password protection +allow_pass_protection=true + +# How much files can one +# user have uploaded to the server. +# Note that it does not include expired files +max_per_ip=8 + +# Timeout for deleting a user uploaded file +file_del_timeout=1800 + +# Whitelisted file types. +# If you uncomment the line below, users +# will be able to upload only plain text files +# List: https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Common_types + +# type_whitelist=[ "text/plain" ] + +# Same as the option above, but in reverse. +# If you uncomment the line below, users will not be able +# to upload plain text files +# type_blacklist=[ "text/plain" ] + +# Name of the instance. +# Change it to fit your website's image +instance_name="blek! File" + +# URL of the instance. +# You must set this to a valid URL +instance_url="" \ No newline at end of file