Server/Mattermost: Unterschied zwischen den Versionen
Zur Navigation springen
Zur Suche springen
Keine Bearbeitungszusammenfassung |
Keine Bearbeitungszusammenfassung |
||
Zeile 1: | Zeile 1: | ||
---- | ---- | ||
: | ; Installation vom Dienst (Server) Mattermost: | ||
Installieren vom Paket ''[[freshports:www/mattermost-server|mattermost-server]]'' | |||
: | |||
- | |||
: <code>pkg install -y mattermost-server</code> | : <code>pkg install -y mattermost-server</code> | ||
<pre></pre> | |||
<pre> | |||
===> Creating groups. | |||
Creating group 'mattermost' with gid '889'. | |||
===> Creating users | |||
Creating user 'mattermost' with uid '889'. | |||
</pre> | |||
<pre> | |||
===> Creating groups. | |||
Using existing group 'mattermost'. | |||
===> Creating users | |||
Using existing user 'mattermost'. | |||
</pre> | |||
<pre></pre> | |||
<!-- | |||
<pre> | |||
Message from ca_root_nss-3.40: | |||
********************************* WARNING ********************************* | |||
FreeBSD does not, and can not warrant that the certification authorities | |||
whose certificates are included in this package have in any way been | |||
audited for trustworthiness or RFC 3647 compliance. | |||
Assessment and verification of trust is the complete responsibility of the | |||
system administrator. | |||
*********************************** NOTE ********************************** | |||
This package installs symlinks to support root certificates discovery by | |||
default for software that uses OpenSSL. | |||
This enables SSL Certificate Verification by client software without manual | |||
intervention. | |||
If you prefer to do this manually, replace the following symlinks with | |||
either an empty file or your site-local certificate bundle. | |||
* /etc/ssl/cert.pem | |||
* /usr/local/etc/ssl/cert.pem | |||
* /usr/local/openssl/cert.pem | |||
*************************************************************************** | |||
</pre> | |||
!--> | |||
(optionales) Begutachten vom Verzeichnis vom Dienst ''mattermost'' | |||
: <code>ls /usr/local/www/mattermost</code> | : <code>ls /usr/local/www/mattermost</code> | ||
<pre> | |||
client fonts i18n templates | |||
</pre> | |||
Aktivieren vom Dienst ''mattermost'' (für jeden Neustart) | |||
: <code>sysrc mattermostd_enable=YES</code> | : <code>sysrc mattermostd_enable=YES</code> | ||
<pre> | |||
mattermostd_enable: -> YES | |||
</pre> | |||
Starten vom Dienst ''mattermost'' | |||
: <code>service mattermostd start</code> | : <code>service mattermostd start</code> | ||
<pre> | |||
Starting mattermostd. | |||
</pre> | |||
Anzeigen (lassen) vom Status vom Dienst ''mattermost'' | |||
: <code>service mattermostd status</code> | : <code>service mattermostd status</code> | ||
<pre> | <pre> | ||
mattermostd is not running. | mattermostd is not running. | ||
</pre> | </pre> | ||
---- | |||
: <code>cp /usr/local/etc/mattermost/config.json.sample /usr/local/etc/mattermost/config.json</code> | : <code>cp /usr/local/etc/mattermost/config.json.sample /usr/local/etc/mattermost/config.json</code> | ||
: <code> | : <code>less /usr/local/etc/mattermost/config.json.sample /usr/local/etc/mattermost/config.json</code> | ||
<pre></pre> | |||
<pre> | |||
"SqlSettings": { | |||
"DriverName": "mysql", | |||
"DataSource": "mmuser:mostest@tcp(dockerhost:3306)/mattermost_test?charset=utf8mb4,utf8&readTimeout=30s&writeTimeout=30s", | |||
"DataSourceReplicas": [], | |||
"DataSourceSearchReplicas": [], | |||
"MaxIdleConns": 20, | |||
"MaxOpenConns": 300, | |||
"Trace": false, | |||
"AtRestEncryptKey": "", | |||
"QueryTimeout": 30 | |||
}, | |||
</pre> | |||
<pre></pre> | |||
---- | |||
; Installation vom Dienst Datenbank: | |||
: Mattermost benennt (aktuell (2018-11-24)) als mögliche Programme als Dienst Datenbank (zum lokalen selbst Betreiben) | |||
:* MySQL | |||
:** 5.6 | |||
:** 5.7 | |||
:** 8 | |||
:* PostgreSQL | |||
:** 9.4+ | |||
: Wie bevorzugen PostgreSQL und die aktuellste Version ist die Version 10. | |||
Installieren vom Paket ''[[freshports:databases/postgresql10-server|postgresql10-server]]'' | |||
: <code>pkg ins -y postgresql10-server</code> | |||
<pre></pre> | |||
<pre> | |||
===> Creating groups. | |||
Creating group 'postgres' with gid '770'. | |||
===> Creating users | |||
Creating user 'postgres' with uid '770'. | |||
=========== BACKUP YOUR DATA! ============= | |||
As always, backup your data before | |||
upgrading. If the upgrade leads to a higher | |||
minor revision (e.g. 8.3.x -> 8.4), a dump | |||
and restore of all databases is | |||
required. This is *NOT* done by the port! | |||
=========================================== | |||
</pre> | |||
<pre> | |||
<!-- | |||
Message from perl5-5.26.2: | |||
The /usr/bin/perl symlink has been removed starting with Perl 5.20. | |||
For shebangs, you should either use: | |||
#!/usr/local/bin/perl | |||
or | |||
#!/usr/bin/env perl | |||
The first one will only work if you have a /usr/local/bin/perl, | |||
the second will work as long as perl is in PATH. | |||
Message from postgresql10-client-10.5: | |||
The PostgreSQL port has a collection of "side orders": | |||
postgresql-docs | |||
For all of the html documentation | |||
p5-Pg | |||
A perl5 API for client access to PostgreSQL databases. | |||
postgresql-tcltk | |||
If you want tcl/tk client support. | |||
postgresql-jdbc | |||
For Java JDBC support. | |||
postgresql-odbc | |||
For client access from unix applications using ODBC as access | |||
method. Not needed to access unix PostgreSQL servers from Win32 | |||
using ODBC. See below. | |||
ruby-postgres, py-psycopg2 | |||
For client access to PostgreSQL databases using the ruby & python | |||
languages. | |||
postgresql-plperl, postgresql-pltcl & postgresql-plruby | |||
For using perl5, tcl & ruby as procedural languages. | |||
postgresql-contrib | |||
Lots of contributed utilities, postgresql functions and | |||
datatypes. There you find pg_standby, pgcrypto and many other cool | |||
things. | |||
etc... | |||
!--> | |||
</pre> | |||
<pre> | |||
Message from postgresql10-server-10.5: | |||
For procedural languages and postgresql functions, please note that | |||
you might have to update them when updating the server. | |||
If you have many tables and many clients running, consider raising | |||
kern.maxfiles using sysctl(8), or reconfigure your kernel | |||
appropriately. | |||
The port is set up to use autovacuum for new databases, but you might | |||
also want to vacuum and perhaps backup your database regularly. There | |||
is a periodic script, /usr/local/etc/periodic/daily/502.pgsql, that | |||
you may find useful. You can use it to backup and perform vacuum on all | |||
databases nightly. Per default, it performs `vacuum analyze'. See the | |||
script for instructions. For autovacuum settings, please review | |||
~pgsql/data/postgresql.conf. | |||
If you plan to access your PostgreSQL server using ODBC, please | |||
consider running the SQL script /usr/local/share/postgresql/odbc.sql | |||
to get the functions required for ODBC compliance. | |||
Please note that if you use the rc script, | |||
/usr/local/etc/rc.d/postgresql, to initialize the database, unicode | |||
(UTF-8) will be used to store character data by default. Set | |||
postgresql_initdb_flags or use login.conf settings described below to | |||
alter this behaviour. See the start rc script for more info. | |||
To set limits, environment stuff like locale and collation and other | |||
things, you can set up a class in /etc/login.conf before initializing | |||
the database. Add something similar to this to /etc/login.conf: | |||
--- | |||
postgres:\ | |||
:lang=en_US.UTF-8:\ | |||
:setenv=LC_COLLATE=C:\ | |||
:tc=default: | |||
--- | |||
and run `cap_mkdb /etc/login.conf'. | |||
Then add 'postgresql_class="postgres"' to /etc/rc.conf. | |||
====================================================================== | |||
To initialize the database, run | |||
/usr/local/etc/rc.d/postgresql initdb | |||
You can then start PostgreSQL by running: | |||
/usr/local/etc/rc.d/postgresql start | |||
For postmaster settings, see ~pgsql/data/postgresql.conf | |||
NB. FreeBSD's PostgreSQL port logs to syslog by default | |||
See ~pgsql/data/postgresql.conf for more info | |||
NB. If you're not using a checksumming filesystem like ZFS, you might | |||
wish to enable data checksumming. It can only be enabled during | |||
the initdb phase, by adding the "--data-checksums" flag to | |||
the postgres_initdb_flags rcvar. Check the initdb(1) manpage | |||
for more info and make sure you understand the performance | |||
implications. | |||
====================================================================== | |||
To run PostgreSQL at startup, add | |||
'postgresql_enable="YES"' to /etc/rc.conf | |||
</pre> | |||
Installieren vom Paket ''[[freshports:databases/postgresql10-contrib|postgresql10-contrib]]'' | |||
: <code>pkg ins -y postgresql10-contrib</code> | |||
<pre></pre> | |||
<pre> | |||
Message from postgresql10-contrib-10.5: | |||
The PostgreSQL contrib utilities have been installed. Please see | |||
/usr/local/share/doc/postgresql/contrib/README | |||
for more information. | |||
</pre> | |||
Aktivieren vom Dienst ''postgresql'' (für jeden Neustart) | |||
: <code>sysrc postgresql_enable=YES</code> | |||
<pre> | |||
postgresql_enable: -> YES | |||
</pre> | |||
Starten vom Dienst ''postgresql'' | |||
: <code>service postgresql initdb</code> | |||
<pre> | |||
The files belonging to this database system will be owned by user "postgres". | |||
This user must also own the server process. | |||
The database cluster will be initialized with locale "C". | |||
The default text search configuration will be set to "english". | |||
Data page checksums are disabled. | |||
creating directory /var/db/postgres/data10 ... ok | |||
creating subdirectories ... ok | |||
selecting default max_connections ... 100 | |||
selecting default shared_buffers ... 128MB | |||
selecting dynamic shared memory implementation ... posix | |||
creating configuration files ... ok | |||
running bootstrap script ... ok | |||
performing post-bootstrap initialization ... ok | |||
syncing data to disk ... ok | |||
WARNING: enabling "trust" authentication for local connections | |||
You can change this by editing pg_hba.conf or using the option -A, or | |||
--auth-local and --auth-host, the next time you run initdb. | |||
Success. You can now start the database server using: | |||
/usr/local/bin/pg_ctl -D /var/db/postgres/data10 -l logfile start | |||
</pre> | |||
: <code>service postgresql start</code> | |||
<pre> | |||
yyyy-mm-dd HH:MM:SS.123 UTC [12345] LOG: could not create IPv6 socket for address "::1": Protocol not supported | |||
yyyy-mm-dd HH:MM:SS.123 UTC [12345] LOG: listening on IPv4 address "127.0.0.1", port 5432 | |||
yyyy-mm-dd HH:MM:SS.123 UTC [12345] LOG: listening on Unix socket "/tmp/.s.PGSQL.5432" | |||
yyyy-mm-dd HH:MM:SS.123 UTC [12345] LOG: ending log output to stderr | |||
yyyy-mm-dd HH:MM:SS.123 UTC [12345] HINT: Future log output will go to log destination "syslog". | |||
</pre> | |||
: <code>service postgresql status</code> | |||
<pre> | <pre> | ||
pg_ctl: server is running (PID: 12345) | |||
/usr/local/bin/postgres "-D" "/var/db/postgres/data10" | |||
</pre> | </pre> | ||
---- | |||
; Erstellung der Datenbank für den Dienst ''mattermost: | |||
--> | |||
: <code>$EDITOR /usr/local/etc/mattermost/config.json.sample /usr/local/etc/mattermost/config.json</code> | |||
---- | ---- | ||
: <code>pkg install -y nginx</code> | : <code>pkg install -y nginx</code> | ||
: <code>sysrc nginx_enable=YES</code> | : <code>sysrc nginx_enable=YES</code> | ||
: <code>service nginx start</code> | : <code>service nginx start</code> |
Version vom 24. November 2018, 10:33 Uhr
- Installation vom Dienst (Server) Mattermost
Installieren vom Paket mattermost-server
pkg install -y mattermost-server
===> Creating groups. Creating group 'mattermost' with gid '889'. ===> Creating users Creating user 'mattermost' with uid '889'.
===> Creating groups. Using existing group 'mattermost'. ===> Creating users Using existing user 'mattermost'.
(optionales) Begutachten vom Verzeichnis vom Dienst mattermost
ls /usr/local/www/mattermost
client fonts i18n templates
Aktivieren vom Dienst mattermost (für jeden Neustart)
sysrc mattermostd_enable=YES
mattermostd_enable: -> YES
Starten vom Dienst mattermost
service mattermostd start
Starting mattermostd.
Anzeigen (lassen) vom Status vom Dienst mattermost
service mattermostd status
mattermostd is not running.
cp /usr/local/etc/mattermost/config.json.sample /usr/local/etc/mattermost/config.json
less /usr/local/etc/mattermost/config.json.sample /usr/local/etc/mattermost/config.json
"SqlSettings": { "DriverName": "mysql", "DataSource": "mmuser:mostest@tcp(dockerhost:3306)/mattermost_test?charset=utf8mb4,utf8&readTimeout=30s&writeTimeout=30s", "DataSourceReplicas": [], "DataSourceSearchReplicas": [], "MaxIdleConns": 20, "MaxOpenConns": 300, "Trace": false, "AtRestEncryptKey": "", "QueryTimeout": 30 },
- Installation vom Dienst Datenbank
- Mattermost benennt (aktuell (2018-11-24)) als mögliche Programme als Dienst Datenbank (zum lokalen selbst Betreiben)
- MySQL
- 5.6
- 5.7
- 8
- PostgreSQL
- 9.4+
- MySQL
- Wie bevorzugen PostgreSQL und die aktuellste Version ist die Version 10.
Installieren vom Paket postgresql10-server
pkg ins -y postgresql10-server
===> Creating groups. Creating group 'postgres' with gid '770'. ===> Creating users Creating user 'postgres' with uid '770'. =========== BACKUP YOUR DATA! ============= As always, backup your data before upgrading. If the upgrade leads to a higher minor revision (e.g. 8.3.x -> 8.4), a dump and restore of all databases is required. This is *NOT* done by the port! ===========================================
<!-- Message from perl5-5.26.2: The /usr/bin/perl symlink has been removed starting with Perl 5.20. For shebangs, you should either use: #!/usr/local/bin/perl or #!/usr/bin/env perl The first one will only work if you have a /usr/local/bin/perl, the second will work as long as perl is in PATH. Message from postgresql10-client-10.5: The PostgreSQL port has a collection of "side orders": postgresql-docs For all of the html documentation p5-Pg A perl5 API for client access to PostgreSQL databases. postgresql-tcltk If you want tcl/tk client support. postgresql-jdbc For Java JDBC support. postgresql-odbc For client access from unix applications using ODBC as access method. Not needed to access unix PostgreSQL servers from Win32 using ODBC. See below. ruby-postgres, py-psycopg2 For client access to PostgreSQL databases using the ruby & python languages. postgresql-plperl, postgresql-pltcl & postgresql-plruby For using perl5, tcl & ruby as procedural languages. postgresql-contrib Lots of contributed utilities, postgresql functions and datatypes. There you find pg_standby, pgcrypto and many other cool things. etc... !-->
Message from postgresql10-server-10.5: For procedural languages and postgresql functions, please note that you might have to update them when updating the server. If you have many tables and many clients running, consider raising kern.maxfiles using sysctl(8), or reconfigure your kernel appropriately. The port is set up to use autovacuum for new databases, but you might also want to vacuum and perhaps backup your database regularly. There is a periodic script, /usr/local/etc/periodic/daily/502.pgsql, that you may find useful. You can use it to backup and perform vacuum on all databases nightly. Per default, it performs `vacuum analyze'. See the script for instructions. For autovacuum settings, please review ~pgsql/data/postgresql.conf. If you plan to access your PostgreSQL server using ODBC, please consider running the SQL script /usr/local/share/postgresql/odbc.sql to get the functions required for ODBC compliance. Please note that if you use the rc script, /usr/local/etc/rc.d/postgresql, to initialize the database, unicode (UTF-8) will be used to store character data by default. Set postgresql_initdb_flags or use login.conf settings described below to alter this behaviour. See the start rc script for more info. To set limits, environment stuff like locale and collation and other things, you can set up a class in /etc/login.conf before initializing the database. Add something similar to this to /etc/login.conf: --- postgres:\ :lang=en_US.UTF-8:\ :setenv=LC_COLLATE=C:\ :tc=default: --- and run `cap_mkdb /etc/login.conf'. Then add 'postgresql_class="postgres"' to /etc/rc.conf. ====================================================================== To initialize the database, run /usr/local/etc/rc.d/postgresql initdb You can then start PostgreSQL by running: /usr/local/etc/rc.d/postgresql start For postmaster settings, see ~pgsql/data/postgresql.conf NB. FreeBSD's PostgreSQL port logs to syslog by default See ~pgsql/data/postgresql.conf for more info NB. If you're not using a checksumming filesystem like ZFS, you might wish to enable data checksumming. It can only be enabled during the initdb phase, by adding the "--data-checksums" flag to the postgres_initdb_flags rcvar. Check the initdb(1) manpage for more info and make sure you understand the performance implications. ====================================================================== To run PostgreSQL at startup, add 'postgresql_enable="YES"' to /etc/rc.conf
Installieren vom Paket postgresql10-contrib
pkg ins -y postgresql10-contrib
Message from postgresql10-contrib-10.5: The PostgreSQL contrib utilities have been installed. Please see /usr/local/share/doc/postgresql/contrib/README for more information.
Aktivieren vom Dienst postgresql (für jeden Neustart)
sysrc postgresql_enable=YES
postgresql_enable: -> YES
Starten vom Dienst postgresql
service postgresql initdb
The files belonging to this database system will be owned by user "postgres". This user must also own the server process. The database cluster will be initialized with locale "C". The default text search configuration will be set to "english". Data page checksums are disabled. creating directory /var/db/postgres/data10 ... ok creating subdirectories ... ok selecting default max_connections ... 100 selecting default shared_buffers ... 128MB selecting dynamic shared memory implementation ... posix creating configuration files ... ok running bootstrap script ... ok performing post-bootstrap initialization ... ok syncing data to disk ... ok WARNING: enabling "trust" authentication for local connections You can change this by editing pg_hba.conf or using the option -A, or --auth-local and --auth-host, the next time you run initdb. Success. You can now start the database server using: /usr/local/bin/pg_ctl -D /var/db/postgres/data10 -l logfile start
service postgresql start
yyyy-mm-dd HH:MM:SS.123 UTC [12345] LOG: could not create IPv6 socket for address "::1": Protocol not supported yyyy-mm-dd HH:MM:SS.123 UTC [12345] LOG: listening on IPv4 address "127.0.0.1", port 5432 yyyy-mm-dd HH:MM:SS.123 UTC [12345] LOG: listening on Unix socket "/tmp/.s.PGSQL.5432" yyyy-mm-dd HH:MM:SS.123 UTC [12345] LOG: ending log output to stderr yyyy-mm-dd HH:MM:SS.123 UTC [12345] HINT: Future log output will go to log destination "syslog".
service postgresql status
pg_ctl: server is running (PID: 12345) /usr/local/bin/postgres "-D" "/var/db/postgres/data10"
- Erstellung der Datenbank für den Dienst mattermost:
-->
$EDITOR /usr/local/etc/mattermost/config.json.sample /usr/local/etc/mattermost/config.json
pkg install -y nginx
sysrc nginx_enable=YES
service nginx start