steps:
- - name: fetch git submodules
- image: node:15-alpine3.12
- commands:
- - apk add git
- - git submodule update --init --recursive --remote
-
- name: chown repo
image: ekidd/rust-musl-builder:1.47.0
user: root
steps:
- - name: fetch git submodules
- image: node:15-alpine3.12
- commands:
- - apk add git
- - git submodule update --init --recursive --remote
-
- name: cargo test
image: rust:1.47-slim-buster
environment:
+++ /dev/null
-[submodule "docs"]
- path = docs
- url = https://github.com/LemmyNet/lemmy-docs
- branch = main
# Contributing
-See [here](https://lemmy.ml/docs/contributing.html) for contributing Instructions.
+See [here](https://join.lemmy.ml/docs/en/contributing/contributing.html) for contributing Instructions.
<br />
<a href="https://join.lemmy.ml">Join Lemmy</a>
·
- <a href="https://lemmy.ml/docs/en/index.html">Documentation</a>
+ <a href="https://join.lemmy.ml/docs/en/index.html">Documentation</a>
·
<a href="https://github.com/LemmyNet/lemmy/issues">Report Bug</a>
·
·
<a href="https://github.com/LemmyNet/lemmy/blob/main/RELEASES.md">Releases</a>
·
- <a href="https://lemmy.ml/docs/en/code_of_conduct.html">Code of Conduct</a>
+ <a href="https://join.lemmy.ml/docs/en/code_of_conduct.html">Code of Conduct</a>
</p>
</p>
- Open source, [AGPL License](/LICENSE).
- Self hostable, easy to deploy.
- - Comes with [Docker](https://lemmy.ml/docs/en/administration/install_docker.html) and [Ansible](https://lemmy.ml/docs/en/administration/install_ansible.html).
+ - Comes with [Docker](https://join.lemmy.ml/docs/en/administration/install_docker.html) and [Ansible](https://join.lemmy.ml/docs/en/administration/install_ansible.html).
- Clean, mobile-friendly interface.
- Only a minimum of a username and password is required to sign up!
- User avatar support.
## Installation
-- [Docker](https://lemmy.ml/docs/en/administration/install_docker.html)
-- [Ansible](https://lemmy.ml/docs/en/administration/install_ansible.html)
+- [Docker](https://join.lemmy.ml/docs/en/administration/install_docker.html)
+- [Ansible](https://join.lemmy.ml/docs/en/administration/install_ansible.html)
## Lemmy Projects
## Contributing
-- [Contributing instructions](https://lemmy.ml/docs/en/contributing/contributing.html)
-- [Docker Development](https://lemmy.ml/docs/en/contributing/docker_development.html)
-- [Local Development](https://lemmy.ml/docs/en/contributing/local_development.html)
+- [Contributing instructions](https://join.lemmy.ml/docs/en/contributing/contributing.html)
+- [Docker Development](https://join.lemmy.ml/docs/en/contributing/docker_development.html)
+- [Local Development](https://join.lemmy.ml/docs/en/contributing/local_development.html)
### Translations
## Upgrading
-If you'd like to make a DB backup before upgrading, follow [this guide](https://lemmy.ml/docs/en/administration/backup_and_restore.html).
+If you'd like to make a DB backup before upgrading, follow [this guide](https://join.lemmy.ml/docs/en/administration/backup_and_restore.html).
-- [Upgrade with manual Docker installation](https://lemmy.ml/docs/en/administration/install_docker.html#updating)
-- [Upgrade with Ansible installation](https://lemmy.ml/docs/en/administration/install_ansible.html)
+- [Upgrade with manual Docker installation](https://join.lemmy.ml/docs/en/administration/install_docker.html#updating)
+- [Upgrade with Ansible installation](https://join.lemmy.ml/docs/en/administration/install_ansible.html)
# Lemmy v0.8.0 Release (2020-10-16)
- The first **federation public beta release**, woohoo :fireworks:
- All Lemmy functionality now works over ActivityPub (except turning remote users into mods/admins)
- Instance allowlist and blocklist
-- Documentation for [admins](https://lemmy.ml/docs/administration_federation.html) and [devs](https://lemmy.ml/docs/contributing_federation_overview.html) on how federation works
+- Documentation for [admins](https://join.lemmy.ml/docs/administration_federation.html) and [devs](https://join.lemmy.ml/docs/contributing_federation_overview.html) on how federation works
- Upgraded to newest versions of @asonix activitypub libraries
- Full local federation setup for manual testing
- Automated testing for nearly every federation action
## Upgrading
-- [with manual Docker installation](https://lemmy.ml/docs/administration_install_docker.html#updating)
-- [with Ansible installation](https://lemmy.ml/docs/administration_install_ansible.html)
+- [with manual Docker installation](https://join.lemmy.ml/docs/administration_install_docker.html#updating)
+- [with Ansible installation](https://join.lemmy.ml/docs/administration_install_ansible.html)
## Testing Federation
Before starting the upgrade, make sure that you have a working backup of your
database and image files. See our
-[documentation](https://lemmy.ml/docs/administration_backup_and_restore.html)
+[documentation](https://join.lemmy.ml/docs/administration_backup_and_restore.html)
for backup instructions.
**With Ansible:**
{
# for more info about the config, check out the documentation
- # https://lemmy.ml/docs/administration_configuration.html
+ # https://join.lemmy.ml/docs/en/administration/configuration.html
# settings related to the postgresql database
database: {
# whether to enable activitypub federation.
enabled: false
# Allows and blocks are described here:
- # https://lemmy.ml/docs/administration_federation.html#instance-allowlist-and-blocklist
+ # https://join.lemmy.ml/docs/en/federation/administration.html#instance-allowlist-and-blocklist
#
# comma separated list of instances with which federation is allowed
# allowed_instances: ""
}
# backend
- location ~ ^/(api|docs|pictrs|feeds|nodeinfo|.well-known) {
+ location ~ ^/(api|pictrs|feeds|nodeinfo|.well-known) {
proxy_pass http://0.0.0.0:{{ lemmy_port }};
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
tls_enabled: true
# json web token for authorization between server and client
jwt_secret: "changeme"
- # path to built documentation
- docs_dir: "/app/documentation"
# address where pictrs is available
pictrs_url: "http://pictrs:8080"
# address where iframely is available
# whether to enable activitypub federation.
enabled: false
# Allows and blocks are described here:
- # https://lemmy.ml/docs/administration_federation.html#instance-allowlist-and-blocklist
+ # https://join.lemmy.ml/docs/en/federation/administration.html#instance-allowlist-and-blocklist
#
# comma separated list of instances with which federation is allowed
allowed_instances: ""
use anyhow::Context;
use config::{Config, ConfigError, Environment, File};
use serde::Deserialize;
-use std::{env, fs, io::Error, net::IpAddr, path::PathBuf, sync::RwLock};
+use std::{env, fs, io::Error, net::IpAddr, sync::RwLock};
static CONFIG_FILE_DEFAULTS: &str = "config/defaults.hjson";
static CONFIG_FILE: &str = "config/config.hjson";
pub bind: IpAddr,
pub port: u16,
pub tls_enabled: bool,
- pub docs_dir: PathBuf,
pub jwt_secret: String,
pub pictrs_url: String,
pub iframely_url: String,
RUN cp ./target/$CARGO_BUILD_TARGET/$RUSTRELEASEDIR/lemmy_server /app/lemmy_server
-# Build the docs
-FROM $RUST_BUILDER_IMAGE as docs
-WORKDIR /app
-RUN cargo install mdbook --git https://github.com/Nutomic/mdBook.git \
- --branch localization --rev 0982a82 --force
-COPY --chown=rust:rust docs ./docs
-RUN ls -la docs/
-RUN mdbook build docs/
-
# The alpine runner
FROM alpine:3.12 as lemmy
# Copy resources
COPY --chown=lemmy:lemmy config/defaults.hjson /config/defaults.hjson
COPY --chown=lemmy:lemmy --from=builder /app/lemmy_server /app/lemmy
-COPY --chown=lemmy:lemmy --from=docs /app/docs/book/ /app/documentation/
RUN chown lemmy:lemmy /app/lemmy
USER lemmy
RUN --mount=type=cache,target=/app/target \
cp target/debug/lemmy_server lemmy_server
-FROM rust:1.47-buster as docs
-WORKDIR /app
-RUN cargo install mdbook --git https://github.com/Nutomic/mdBook.git \
- --branch localization --rev 0982a82 --force
-COPY docs ./docs
-RUN mdbook build docs/
-
FROM ubuntu:20.10
# Install libpq for postgres and espeak
# Copy resources
COPY config/defaults.hjson /config/defaults.hjson
COPY --from=rust /app/lemmy_server /app/lemmy
-COPY --from=docs /app/docs/book/ /app/documentation/
EXPOSE 8536
CMD ["/app/lemmy"]
# Upload limit for pictshare
client_max_body_size 50M;
- location ~ ^/(api|docs|pictrs|feeds|nodeinfo|.well-known) {
+ location ~ ^/(api|pictrs|feeds|nodeinfo|.well-known) {
proxy_pass http://lemmy-alpha;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
# Upload limit for pictshare
client_max_body_size 50M;
- location ~ ^/(api|docs|pictrs|feeds|nodeinfo|.well-known) {
+ location ~ ^/(api|pictrs|feeds|nodeinfo|.well-known) {
proxy_pass http://lemmy-beta;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
# Upload limit for pictshare
client_max_body_size 50M;
- location ~ ^/(api|docs|pictrs|feeds|nodeinfo|.well-known) {
+ location ~ ^/(api|pictrs|feeds|nodeinfo|.well-known) {
proxy_pass http://lemmy-gamma;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
# Upload limit for pictshare
client_max_body_size 50M;
- location ~ ^/(api|docs|pictrs|feeds|nodeinfo|.well-known) {
+ location ~ ^/(api|pictrs|feeds|nodeinfo|.well-known) {
proxy_pass http://lemmy-delta;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
# Upload limit for pictshare
client_max_body_size 50M;
- location ~ ^/(api|docs|pictrs|feeds|nodeinfo|.well-known) {
+ location ~ ^/(api|pictrs|feeds|nodeinfo|.well-known) {
proxy_pass http://lemmy-epsilon;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
{
# for more info about the config, check out the documentation
- # https://lemmy.ml/docs/administration_configuration.html
+ # https://join.lemmy.ml/docs/en/administration/configuration.html
setup: {
# username for the admin user
RUN cp ./target/$CARGO_BUILD_TARGET/$RUSTRELEASEDIR/lemmy_server /app/lemmy_server
-# Build the docs
-FROM $RUST_BUILDER_IMAGE as docs
-WORKDIR /app
-RUN cargo install mdbook --git https://github.com/Nutomic/mdBook.git \
- --branch localization --rev 0982a82 --force
-COPY --chown=rust:rust docs ./docs
-RUN mdbook build docs/
-
# The alpine runner
FROM alpine:3.12 as lemmy
# Copy resources
COPY --chown=lemmy:lemmy config/defaults.hjson /config/defaults.hjson
COPY --chown=lemmy:lemmy --from=builder /app/lemmy_server /app/lemmy
-COPY --chown=lemmy:lemmy --from=docs /app/docs/book/ /app/documentation/
RUN chown lemmy:lemmy /app/lemmy
USER lemmy
RUN cp ./target/release/lemmy_server /app/lemmy_server
-# Build the docs
-FROM $RUST_BUILDER_IMAGE as docs
-WORKDIR /app
-RUN cargo install mdbook --git https://github.com/Nutomic/mdBook.git --branch localization --rev 0982a82 --force
-COPY docs ./docs
-RUN mdbook build docs/
-
# The Debian runner
FROM debian:buster-slim as lemmy
# Copy resources
COPY --chown=lemmy:lemmy config/defaults.hjson /config/defaults.hjson
COPY --chown=lemmy:lemmy --from=builder /app/lemmy_server /app/lemmy
-COPY --chown=lemmy:lemmy --from=docs /app/docs/book/ /app/documentation/
RUN chown lemmy:lemmy /app/lemmy
USER lemmy
+++ /dev/null
-Subproject commit cf3236bb620048897048027d8cdff34401ad85ee
.configure(|cfg| images::config(cfg, &rate_limiter))
.configure(nodeinfo::config)
.configure(webfinger::config)
- .service(actix_files::Files::new("/docs", Settings::get().docs_dir))
})
.bind((settings.bind, settings.port))?
.run()