summaryrefslogtreecommitdiffstats
path: root/docs
diff options
context:
space:
mode:
Diffstat (limited to 'docs')
-rw-r--r--docs/Makefile20
-rw-r--r--docs/conf.py26
-rw-r--r--docs/index.rst13
-rw-r--r--docs/installation.rst76
-rw-r--r--docs/make.bat35
5 files changed, 170 insertions, 0 deletions
diff --git a/docs/Makefile b/docs/Makefile
new file mode 100644
index 0000000..d4bb2cb
--- /dev/null
+++ b/docs/Makefile
@@ -0,0 +1,20 @@
+# Minimal makefile for Sphinx documentation
+#
+
+# You can set these variables from the command line, and also
+# from the environment for the first two.
+SPHINXOPTS ?=
+SPHINXBUILD ?= sphinx-build
+SOURCEDIR = .
+BUILDDIR = _build
+
+# Put it first so that "make" without argument is like "make help".
+help:
+ @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
+
+.PHONY: help Makefile
+
+# Catch-all target: route all unknown targets to Sphinx using the new
+# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
+%: Makefile
+ @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
diff --git a/docs/conf.py b/docs/conf.py
new file mode 100644
index 0000000..73e4692
--- /dev/null
+++ b/docs/conf.py
@@ -0,0 +1,26 @@
+# Configuration file for the Sphinx documentation builder.
+#
+# For the full list of built-in configuration values, see the documentation:
+# https://www.sphinx-doc.org/en/master/usage/configuration.html
+
+# -- Project information -----------------------------------------------------
+# https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information
+
+project = "Takahē"
+copyright = "2022, Andrew Godwin"
+author = "Andrew Godwin"
+
+# -- General configuration ---------------------------------------------------
+# https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration
+
+extensions: list = []
+
+templates_path = ["_templates"]
+exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"]
+
+
+# -- Options for HTML output -------------------------------------------------
+# https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output
+
+html_theme = "alabaster"
+html_static_path = ["_static"]
diff --git a/docs/index.rst b/docs/index.rst
new file mode 100644
index 0000000..a50c369
--- /dev/null
+++ b/docs/index.rst
@@ -0,0 +1,13 @@
+Takahē
+======
+
+
+Welcome to the Takahē documentation! Takahē is an ActivityPub server, designed
+for low- to medium-size installations, and with the ability to serve multiple
+domains at once.
+
+.. toctree::
+ :maxdepth: 2
+ :caption: Contents:
+
+ installation
diff --git a/docs/installation.rst b/docs/installation.rst
new file mode 100644
index 0000000..9c39a9d
--- /dev/null
+++ b/docs/installation.rst
@@ -0,0 +1,76 @@
+Installation
+============
+
+We recommend running using the Docker/OCI image; this contains all of the
+necessary dependencies and static file handling preconfigured for you.
+
+All configuration is done via either environment variables, or online through
+the web interface.
+
+
+Prerequisites
+-------------
+
+* SSL support (Takahē *requires* HTTPS)
+* Something that can run Docker/OCI images ("serverless" platforms are fine!)
+* A PostgreSQL 14 (or above) database
+* One of these to store uploaded images and media:
+ * Amazon S3
+ * Google Cloud Storage
+ * Writable local directory (must be accessible by all running copies!)
+
+
+Environment Variables
+---------------------
+
+All of these variables are *required* for a working installation, and should
+be provided from the first boot.
+
+* ``PGHOST``, ``PGPORT``, ``PGUSER``, ``PGDATABASE``, and ``PGPASSWORD`` are the
+ standard PostgreSQL environment variables for configuring your database.
+
+* ``TAKAHE_MEDIA_BACKEND`` must be one of ``local``, ``s3`` or ``gcs``.
+
+ * If it is set to ``local``, you must also provide ``TAKAHE_MEDIA_ROOT``,
+ the path to the local media directory, and ``TAKAHE_MEDIA_URL``, a
+ fully-qualified URL prefix that serves that directory.
+
+ * If it is set to ``gcs``, you must also provide ``TAKAHE_MEDIA_BUCKET``,
+ the name of the bucket to store files in.
+
+ * If it is set to ``s3``, you must also provide ``TAKAHE_MEDIA_BUCKET``,
+ the name of the bucket to store files in.
+
+* ``TAKAHE_MAIN_DOMAIN`` should be the domain name (without ``https://``) that
+ will be used for default links (such as in emails). It does *not* need to be
+ the same as any domain you are hosting user accounts on.
+
+* ``TAKAHE_EMAIL_HOST`` and ``TAKAHE_EMAIL_PORT`` (along with
+ ``TAKAHE_EMAIL_USER`` and ``TAKAHE_EMAIL_PASSWORD``, if needed) should point
+ to an SMTP server Takahe can use for sending email. Email is *required*, to
+ allow account creation and password resets.
+
+ * If you are using SendGrid, you can just set an API key in
+ ``TAKAHE_EMAIL_SENDGRID_KEY`` instead.
+
+* ``TAKAHE_EMAIL_FROM`` is the email address that emails from the system will
+ appear to come from.
+
+* ``TAKAHE_AUTO_ADMIN_EMAIL`` should be an email address that you would like to
+ be automatically promoted to administrator when it signs up. You only need
+ this for initial setup, and can unset it after that if you like.
+
+
+Making An Admin Account
+-----------------------
+
+Once the webserver is up and working, go to the "create account" flow and
+create a new account using the email you specified in
+``TAKAHE_AUTO_ADMIN_EMAIL``.
+
+Once you set your password using the link emailed to you, you will have an
+admin account.
+
+If your email settings have a problem and you don't get the email, don't worry;
+fix them and then follow the "reset my password" flow on the login screen, and
+you'll get another password reset email that you can use.
diff --git a/docs/make.bat b/docs/make.bat
new file mode 100644
index 0000000..954237b
--- /dev/null
+++ b/docs/make.bat
@@ -0,0 +1,35 @@
+@ECHO OFF
+
+pushd %~dp0
+
+REM Command file for Sphinx documentation
+
+if "%SPHINXBUILD%" == "" (
+ set SPHINXBUILD=sphinx-build
+)
+set SOURCEDIR=.
+set BUILDDIR=_build
+
+%SPHINXBUILD% >NUL 2>NUL
+if errorlevel 9009 (
+ echo.
+ echo.The 'sphinx-build' command was not found. Make sure you have Sphinx
+ echo.installed, then set the SPHINXBUILD environment variable to point
+ echo.to the full path of the 'sphinx-build' executable. Alternatively you
+ echo.may add the Sphinx directory to PATH.
+ echo.
+ echo.If you don't have Sphinx installed, grab it from
+ echo.https://www.sphinx-doc.org/
+ exit /b 1
+)
+
+if "%1" == "" goto help
+
+%SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
+goto end
+
+:help
+%SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
+
+:end
+popd