forked from mCaptcha/website
11 lines
3.3 KiB
XML
11 lines
3.3 KiB
XML
|
<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>self-hosted on</title><link>/docs/self-hosted/</link><description>Recent content in self-hosted on</description><generator>Hugo -- gohugo.io</generator><language>en-US</language><atom:link href="/docs/self-hosted/index.xml" rel="self" type="application/rss+xml"/><item><title>Getting started</title><link>/docs/self-hosted/getting-started/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>/docs/self-hosted/getting-started/</guid><description>Get started There are two main ways to self-host mCaptcha:
|
||
|
Bare metal With Docker</description></item><item><title>Docker</title><link>/docs/self-hosted/docker/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>/docs/self-hosted/docker/</guid><description>Docker 1. Configure mcaptcha is highly configurable.
|
||
|
Configuration is applied/merged in the following order:
|
||
|
path to configuration file passed in via MCAPTCHA_CONFIG ./config/default.toml /etc/mcaptcha/config.toml environment variables. See CONFIGURATION.md for configurable options.
|
||
|
2. Run image If you have already have a Postgres instance running, then:
|
||
|
docker run -p &lt;host-machine-port&gt;:&lt;port-in-configuration-file&gt; \ --add-host=database:&lt;database-ip-addrss&gt; \ -e RUST_LOG=debug \ -e DATABASE_URL=&#34;postgres://&lt;db-user&gt;:&lt;db-password&gt;@database:&lt;db-port&gt;/&lt;db-name&gt;&#34; \ mcaptcha/mcaptcha:latest If you don&rsquo;t have a Postgres instance running, you can either install one using a package manager or launch one with docker.</description></item><item><title>Deploy bare metal</title><link>/docs/self-hosted/bare-metal/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>/docs/self-hosted/bare-metal/</guid><description>2. Configure mcaptcha is highly configurable.
|
||
|
Configuration is applied/merged in the following order:
|
||
|
path to configuration file passed in via MCAPTCHA_CONFIG ./config/default.toml /etc/mcaptcha/config.toml environment variables. 1. Install postgres if you don&rsquo;t have it already. For Debian based distributions:
|
||
|
sudo apt install postgres 2. Create new user for running mcaptcha $ sudo useradd -b /srv -m -s /usr/bin/zsh mcaptcha 3. Create new user in Postgres $ sudo -iu postgres # switch to `postgres` user $ psql postgres=# CREATE USER mcaptcha WITH PASSWORD &#39;my super long password and yes you need single quote`; $ createdb -O mcaptcha mcaptcha # create db &#39;mcaptcha&#39; with &#39;mcaptcha&#39; as owner 4.</description></item><item><title>Databse and cache</title><link>/docs/self-hosted/dependencies/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>/docs/self-hosted/dependencies/</guid><description>Notes Database Database migrations are baked into the server binary so don&rsquo;t worry about them.
|
||
|
When compiling from source, unset database configuration(comment out database configuration/ unset relevant environment variables). mCaptcha uses sqlx database client library which checks SQL queries at compile time. So if you are starting with a fresh database without migrations applied, compilation will fail.
|
||
|
Redis Redis is an optional dependency.</description></item></channel></rss>
|