You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: friendica/content.md
+30-60Lines changed: 30 additions & 60 deletions
Original file line number
Diff line number
Diff line change
@@ -1,32 +1,24 @@
1
1
# What is Friendica?
2
2
3
-
Friendica is a decentralised communications platform that integrates social communication.
4
-
Our platform links to independent social projects and corporate services.
3
+
Friendica is a decentralised communications platform that integrates social communication. Our platform links to independent social projects and corporate services.
The images are designed to be used in a micro-service environment.
11
-
There are two types of the image you can choose from.
9
+
The images are designed to be used in a micro-service environment. There are two types of the image you can choose from.
12
10
13
-
The `apache` tag contains a full Friendica installation including an apache web server.
14
-
It is designed to be easy to use and gets you running pretty fast.
15
-
This is also the default for the `latest` tag and version tags that are not further specified.
11
+
The `apache` tag contains a full Friendica installation including an apache web server. It is designed to be easy to use and gets you running pretty fast. This is also the default for the `latest` tag and version tags that are not further specified.
16
12
17
-
The second option is a `fpm` container.
18
-
It is based on the [php-fpm](https://hub.docker.com/_/php/) image and runs a fastCGI-Process that serves your Friendica server.
19
-
To use this image it must be combined with any Webserver that can proxy the http requests to the FastCGI-port of the container.
13
+
The second option is a `fpm` container. It is based on the [php-fpm](https://hub.docker.com/_/php/) image and runs a fastCGI-Process that serves your Friendica server. To use this image it must be combined with any Webserver that can proxy the http requests to the FastCGI-port of the container.
20
14
21
-
[](http://play-with-docker.com?stack=https://raw.githubusercontent.com/nupplaphil/friendica-docker/fec33c98be957436279b7074ca08068b18622627/stack.yml)
[](http://play-with-docker.com?stack=https://raw.githubusercontent.com/nupplaphil/friendica-docker/fec33c98be957436279b7074ca08068b18622627/stack.yml) (Admin-E-Mail: `[email protected]`)
23
16
24
17
## Using the apache image
25
18
26
19
You need at least one other mariadb/mysql-container to link it to Friendica.
27
20
28
-
The apache image contains a webserver and exposes port 80.
29
-
To start the container type:
21
+
The apache image contains a webserver and exposes port 80. To start the container type:
30
22
31
23
```console
32
24
$ docker run -d -p 8080:80 --link some-mysql:mysql friendica/server
@@ -36,20 +28,13 @@ Now you can access the Friendica installation wizard at http://localhost:8080/ f
36
28
37
29
## Using the fpm image
38
30
39
-
To use the fpm image you need an additional web server that can proxy http-request to the fpm-port of the container.
40
-
For fpm connection this container exposes port 9000.
41
-
In most cases you might want use another container or your host as proxy.
42
-
If you use your host you can address your Friendica container directly on port 9000.
43
-
If you use another container, make sure that you add them to the same docker network (via `docker run --network <NAME> ...` or a `docker-compose` file).
44
-
In both cases you don't want to map the fpm port to you host.
31
+
To use the fpm image you need an additional web server that can proxy http-request to the fpm-port of the container. For fpm connection this container exposes port 9000. In most cases you might want use another container or your host as proxy. If you use your host you can address your Friendica container directly on port 9000. If you use another container, make sure that you add them to the same docker network (via `docker run --network <NAME> ...` or a `docker-compose` file). In both cases you don't want to map the fpm port to you host.
45
32
46
33
```console
47
34
$ docker run -d friendica/server:fpm
48
35
```
49
36
50
-
As the fastCGI-Process is not capable of serving static files (style sheets, images, ...) the webserver needs access to these files.
51
-
This can be achieved with the `volumes-from` option.
52
-
You can find more information in the docker-compose section.
37
+
As the fastCGI-Process is not capable of serving static files (style sheets, images, ...) the webserver needs access to these files. This can be achieved with the `volumes-from` option. You can find more information in the docker-compose section.
53
38
54
39
## Using the cron job
55
40
@@ -62,6 +47,7 @@ There are three options to enable the cron-job for Friendica:
62
47
## Possible Environment Variables
63
48
64
49
**Friendica Settings**
50
+
65
51
-`FRIENDICA_ADMIN_MAIL` E-Mail address of the administrator.
66
52
-`FRIENDICA_TZ` The default localization of the Friendica server.
67
53
-`FRIENDICA_LANG` The default language of the Friendica server.
@@ -72,11 +58,13 @@ There are three options to enable the cron-job for Friendica:
72
58
-`FRIENDICA_DATA_DIR` The data directory of the Friendica server (Default: /var/www/data).
73
59
74
60
**Friendica Logging**
61
+
75
62
-`FRIENDICA_DEBUGGING` If set to `true`, the logging of Friendica is enabled.
76
63
-`FRIENDICA_LOGFILE` (optional) The path to the logfile (Default: /var/www/friendica.log).
77
64
-`FRIENDICA_LOGLEVEL` (optional) The loglevel to log (Default: notice).
78
65
79
66
**Database** (**required at installation**)
67
+
80
68
-`MYSQL_USERNAME` Username for the database user using mysql.
81
69
-`MYSQL_USER` Username for the database user using mariadb.
82
70
-`MYSQL_PASSWORD` Password for the database user using mysql / mariadb.
@@ -85,12 +73,14 @@ There are three options to enable the cron-job for Friendica:
85
73
-`MYSQL_PORT` Port of the database server using mysql / mariadb (Default: `3306`)
86
74
87
75
**Lock Driver (Redis)**
76
+
88
77
-`REDIS_HOST` The hostname of the redis instance (in case of locking).
89
78
-`REDIS_PORT` (optional) The port of the redis instance (in case of locking).
90
79
-`REDIS_PW` (optional) The password for the redis instance (in case of locking).
91
80
-`REDIS_DB` (optional) The database instance of the redis instance (in case of locking).
92
81
93
82
**Develop/Release Candidat Settings**
83
+
94
84
-`FRIENDICA_UPGRADE` If set to `true`, a develop or release candidat node will get updated at startup.
95
85
-`FRIENDICA_REPOSITORY` If set, a custom repository will be chosen (Default: `friendica`)
96
86
-`FRIENDICA_ADDONS_REPO` If set, a custom repository for the addons will be chosen (Default: `friendica`)
@@ -107,8 +97,7 @@ The binary `ssmtp` is used for the `mail()` support of Friendica.
107
97
108
98
You have to set the `--hostname/-h` parameter correctly to use the right domainname for the `mail()` command.
109
99
110
-
You have to set a valid SMTP-MTA for the `SMTP` environment variable to enable mail support in Friendica.
111
-
A valid SMTP-MTA would be, for example, `mx.example.org`.
100
+
You have to set a valid SMTP-MTA for the `SMTP` environment variable to enable mail support in Friendica. A valid SMTP-MTA would be, for example, `mx.example.org`.
112
101
113
102
The following environment variables are possible for the SMTP examples.
114
103
@@ -127,12 +116,9 @@ You have to link a running database container, e. g. `--link my-mysql:mysql`, an
127
116
128
117
## Persistent data
129
118
130
-
The Friendica installation and all data beyond what lives in the database (file uploads, etc) is stored in the [unnamed docker volume](https://docs.docker.com/engine/tutorials/dockervolumes/#adding-a-data-volume) volume `/var/www/html`.
131
-
The docker daemon will store that data within the docker directory `/var/lib/docker/volumes/...`.
132
-
That means your data is saved even if the container crashes, is stopped or deleted.
119
+
The Friendica installation and all data beyond what lives in the database (file uploads, etc) is stored in the [unnamed docker volume](https://docs.docker.com/engine/tutorials/dockervolumes/#adding-a-data-volume) volume `/var/www/html`. The docker daemon will store that data within the docker directory `/var/lib/docker/volumes/...`. That means your data is saved even if the container crashes, is stopped or deleted.
133
120
134
-
To make your data persistent to upgrading and get access for backups is using named docker volume or mount a host folder.
135
-
To achieve this you need one volume for your database container and Friendica.
121
+
To make your data persistent to upgrading and get access for backups is using named docker volume or mount a host folder. To achieve this you need one volume for your database container and Friendica.
136
122
137
123
Friendica:
138
124
@@ -156,9 +142,7 @@ $ docker run -d \
156
142
157
143
## Automatic installation
158
144
159
-
The Friendica image supports auto configuration via environment variables.
160
-
You can preconfigure everything that is asked on the install page on first run.
161
-
To enable the automatic installation, there are two possibilities:
145
+
The Friendica image supports auto configuration via environment variables. You can preconfigure everything that is asked on the install page on first run. To enable the automatic installation, there are two possibilities:
162
146
163
147
### Environment Variables
164
148
@@ -172,16 +156,13 @@ You have to set at least the following environment variables (others are optiona
172
156
173
157
### Using a predefined config file
174
158
175
-
You can create a `local.config.php` and `COPY` it to `/usr/src/config`.
176
-
If no other environment variable is set, this `local.config.php` will get copied to the config path.
159
+
You can create a `local.config.php` and `COPY` it to `/usr/src/config`. If no other environment variable is set, this `local.config.php` will get copied to the config path.
177
160
178
161
# Docker Secrets
179
162
180
163
More information can be found here https://docs.docker.com/engine/swarm/secrets/.
181
164
182
-
As an alternative to passing sensitive information via environment variables, _FILE may be appended to the previously listed environment variables, causing the initialization script to load the values for those variables from files present in the container.
183
-
In particular, this can be used to load passwords from Docker secrets stored in /run/secrets/<secret_name> files.
184
-
For example:
165
+
As an alternative to passing sensitive information via environment variables, _FILE may be appended to the previously listed environment variables, causing the initialization script to load the values for those variables from files present in the container. In particular, this can be used to load passwords from Docker secrets stored in /run/secrets/<secret_name> files. For example:
185
166
186
167
```yaml
187
168
version: '3.2'
@@ -226,41 +207,34 @@ secrets:
226
207
mysql_password:
227
208
file: ./mysql_password.txt # put mysql password to this file using docker-secrets to manage it
228
209
```
210
+
229
211
Currently, this is only supported for `MYSQL_PASSWORD`.
230
212
231
213
# Maintenance of the image
232
214
233
215
## Updating to a newer version
234
216
235
-
There are differences between the deveop (everything which ends with `-rc` or `-dev`) and the stable (the rest) branches.
217
+
There are differences between the develop (everything which ends with `-rc` or `-dev`) and the stable (the rest) branches.
236
218
237
219
### Updating stable
238
220
239
-
You have to pull the latest image from the hub (`docker pull friendica`).
240
-
The stable branch gets checked at every startup and will get updated if no installation was found or a new image is used.
221
+
You have to pull the latest image from the hub (`docker pull friendica`). The stable branch gets checked at every startup and will get updated if no installation was found or a new image is used.
241
222
242
223
### Updating develop
243
224
244
-
You don't need to pull the image for each commit in [friendica](https://github.com/friendica/friendica/).
245
-
Instead, the develop branch will get updated if no installation was found or the environment variable `FRIENDICA_UPGRADE` is set to `true`.
225
+
You don't need to pull the image for each commit in [friendica](https://github.com/friendica/friendica/). Instead, the develop branch will get updated if no installation was found or the environment variable `FRIENDICA_UPGRADE` is set to `true`.
246
226
247
227
It will clone the latest Friendica version and copy it to your working directory.
248
228
249
229
# Running this image with docker-compose
250
230
251
-
The easiest way to get a fully featured and functional setup is using a `docker-compose` file.
252
-
There are too many different possibilities to setup your system, so here are only some examples what you have to look for.
231
+
The easiest way to get a fully featured and functional setup is using a `docker-compose` file. There are too many different possibilities to setup your system, so here are only some examples what you have to look for.
253
232
254
-
At first make sure you have chosen the right base image (fpm or apache) and added the features you wanted (see below).
255
-
In every case you want to add a database container and docker volumes to get easy access to your persistent data.
256
-
When you want your server reachable from the internet adding HTTPS-encryption is mandatory!
257
-
See below for more information.
233
+
At first make sure you have chosen the right base image (fpm or apache) and added the features you wanted (see below). In every case you want to add a database container and docker volumes to get easy access to your persistent data. When you want your server reachable from the internet adding HTTPS-encryption is mandatory! See below for more information.
258
234
259
235
## Base version - apache
260
236
261
-
This version will use the apache image and add a mariaDB container.
262
-
The volumes are set to keep your data persistent.
263
-
This setup provides **no ssl encryption** and is intended to run behind a proxy.
237
+
This version will use the apache image and add a mariaDB container. The volumes are set to keep your data persistent. This setup provides **no ssl encryption** and is intended to run behind a proxy.
264
238
265
239
Make sure to set the variable `MYSQL_PASSWORD` before run this setup.
266
240
@@ -305,20 +279,16 @@ Then run `docker-compose up -d`, now you can access Friendica at http://localhos
305
279
306
280
## Base version - FPM
307
281
308
-
When using the FPM image you need another container that acts as web server on port 80 and proxies requests to the Friendica container.
309
-
In this example a simple nginx container is combined with the Friendica-fpm image and a MariaDB database container.
310
-
The data is stored in docker volumes.
311
-
The nginx container also need access to static files from your Friendica installation.
312
-
It gets access to all the volumes mounted to Friendica via the `volumes_from` option.
313
-
The configuration for nginx is stored in the configuration file `nginx.conf` that is mounted into the container.
282
+
When using the FPM image you need another container that acts as web server on port 80 and proxies requests to the Friendica container. In this example a simple nginx container is combined with the Friendica-fpm image and a MariaDB database container. The data is stored in docker volumes. The nginx container also need access to static files from your Friendica installation. It gets access to all the volumes mounted to Friendica via the `volumes_from` option. The configuration for nginx is stored in the configuration file `nginx.conf` that is mounted into the container.
314
283
315
284
An example can be found in the [examples section](https://github.com/friendica/docker/tree/master/.examples).
316
285
317
286
As this setup does **not include encryption** it should to be run behind a proxy.
318
287
319
288
Prerequisites for this example:
320
-
- Make sure to set the variable `MYSQL_PASSWORD` before you run the setup.
321
-
- Create a `nginx.conf` in the same directory as the docker-compose.yml file (take it from [example](https://github.com/friendica/docker/tree/master/.examples/docker-compose/with-traefik-proxy/mariadb-cron-smtp/fpm/web/nginx.conf))
289
+
290
+
- Make sure to set the variable `MYSQL_PASSWORD` before you run the setup.
291
+
- Create a `nginx.conf` in the same directory as the docker-compose.yml file (take it from [example](https://github.com/friendica/docker/tree/master/.examples/docker-compose/with-traefik-proxy/mariadb-cron-smtp/fpm/web/nginx.conf))
0 commit comments