eve-doc/home.markdown

66 lines
1.5 KiB
Markdown

## Database
### postgres
- Host: postgres
```bash
$ create-postgres-user-and-database foo bar # create user `foo` and give him access to database `bar`
```
Administration shell:
```bash
$ sudo psql -h postgres -U postgres
psql> \l # list databases
psql> \c <database> # connect to database
psql> \d # show tables
$ sudo pg_dump -h postgres -U postgres <dbname> > dump.sql
$ sudo psql -h postgres -U postgres < dump.sql
```
### mysql
- Host: mysql
```bash
$ create-mysql-user-and-database foo # create database and user `foo`
```
## List zfs snapshots
```bash
$ cd /data/containers/<name>/rootfs/.zfs
$ ls
```
## Ldap
Administration: https://ldap.higgsboson.tk
| objectclass | description |
| ----------- | ---------------------------- |
| mailaccount | access imap/smtp |
| owncloud | https://cloud.higgsboson.tk |
| gitlab | https://git.higgsboson.tk |
## Mail
| Key | Value |
| ----------- |----------------------------- |
| Imap | imap.higgsboson.tk, Port 143 |
| Smtp | smtp.higgsboson.tk, Port 567 |
| Webmail | https://mail.higgsboson.tk |
| Encryption | STARTTLS or TLS |
| MX-Record | mail.higgsboson.tk |
| SRV-Record | v=spf1 a:mail.higgsboson.tk ip6:2a01:4f8:210:31fd:1::10 -all |
## LXC
```bash
$ lxc-attach -n <name> # login
$ systemctl start lxc@<name> # start container
$ systemctl stop lxc@<name> # stop container
```