exfile v0.2.2 Exfile.Config

A simple server responsible for Exfile configuration.

The default configuration:

%{
  "store" => [Exfile.Backend.FileSystem, %{
    directory: Path.expand("./tmp/store"),
    max_size: nil,
    hasher: Exfile.Hasher.Random
  }],
  "cache" => [Exfile.Backend.FileSystem, %{
    directory: Path.expand("./tmp/cache"),
    max_size: nil,
    hasher: Exfile.Hasher.Random
  }]
}

Summary

Functions

Get “allow_downloads_from”. Defaults to :all

Get “allow_uploads_to”. Defaults to ["cache"]

Get “cdn_host”. Defaults to nil

Get the initialized backend for “name”

Re-initialize all registered backends

Get “secret”. Defaults to nil

Functions

allow_downloads_from()

Get “allow_downloads_from”. Defaults to :all

allow_uploads_to()

Get “allow_uploads_to”. Defaults to ["cache"]

cdn_host()

Get “cdn_host”. Defaults to nil

get_backend(name)

Get the initialized backend for “name”

refresh_backend_config()

Re-initialize all registered backends

secret()

Get “secret”. Defaults to nil