summaryrefslogtreecommitdiff
path: root/config/config.exs
blob: 6468a160ab47fd82486c3f4c9f86bb7f62ccb3fb (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
import Config

config :logger, level: :debug

config :logger, :console,
  format: "$date $time [$level] $metadata$message\n",
  metadata: :all

config :phoenix, :json_library, Jason

# General application configuration
config :nola,
  namespace: Nola

config :nola, :data_path, "priv"

config :nola, :brand,
  name: "Nola",
  source_url: "https://phab.random.sh/source/Nola/",
  owner: "Ashamed Owner",
  owner_email: "do@not.mail.him"

config :ex_aws,
  region: "us-east-1",
  host: "s3.wasabisys.com",
  s3: [
    host: "s3.wasabisys.com",
    region: "us-east-1",
    scheme: "https://"
  ]

# Configures the endpoint
config :nola, NolaWeb.Endpoint,
  url: [host: "localhost"],
  secret_key_base: "cAFb7x2p/D7PdV8/C6Os18uygoD0FVQh3efNEFc5+5L529q3dofZtZye/BG12MRZ",
  render_errors: [view: NolaWeb.ErrorView, accepts: ~w(html json)],
  server: true,
  live_view: [signing_salt: "CHANGE_ME_FFS"],
  pubsub: [name: NolaWeb.PubSub, adapter: Phoenix.PubSub.PG2]

config :mime, :types, %{"text/event-stream" => ["sse"]}

config :nola, :lastfm,
  api_key: "x",
  api_secret: "x"

config :nola, :youtube,
  api_key: "x",
  invidious: "yewtu.be"

config :mnesia,
  dir: '.mnesia/#{Mix.env()}/#{node()}'

config :nola, Nola.Plugins.Link,
  proxy: nil,
  scraper: [
    service: "usescraper",
    config: [
      api_key: "xxxx",
      http_options: [
        timeout: :timer.seconds(120),
        recv_timeout: :timer.seconds(120)
      ]
    ]
  ],
  store: [
    ttl: :timer.hours(24),
    inhibit: :timer.hours(16),
    interval: :timer.minutes(30)
  ],
  handlers: [
    "Nola.Plugins.Link.Image": [],
    "Nola.Plugins.Link.HTML": [],
    "Nola.Plugins.Link.PDF": [],
    "Nola.Plugins.Link.YouTube": [
      invidious: true
    ],
    "Nola.Plugins.Link.Twitter": [
      expand_quoted: true
    ],
    "Nola.Plugins.Link.Imgur": [],
    "Nola.Plugins.Link.Github": [],
    "Nola.Plugins.Link.Reddit": [],
    "Nola.Plugins.Link.ImgDebridLink": []
  ]

config :floki, :html_parser, Floki.HTMLParser.FastHtml

# Import environment specific config. This must remain at the bottom
# of this file so it overrides the configuration defined above.
import_config "#{Mix.env()}.exs"