Compare commits
44 Commits
c6db39b55a
...
master
Author | SHA1 | Date | |
---|---|---|---|
8a9b3db287
|
|||
a72c67f070
|
|||
47745b7bc9
|
|||
c568f00db1
|
|||
99b6959c84
|
|||
fa65726096
|
|||
f9eaf7a41e
|
|||
d825b1f391
|
|||
b296a3f2fe
|
|||
8ff89c9ee1
|
|||
62a4e598bd
|
|||
b65aaa5072
|
|||
98b7aff274
|
|||
6eaf7f7390
|
|||
32e80282ef
|
|||
c8bd9f4ec3
|
|||
d3d189e284
|
|||
71fe688ef8
|
|||
c5d0f96bdf
|
|||
eea8db6499
|
|||
7893349da4
|
|||
a4c61f94e6
|
|||
da0a261ddd
|
|||
b9954d1bba
|
|||
3a23c08f37
|
|||
d1500ea373
|
|||
a77fefcded
|
|||
41fac2c4f9
|
|||
280ea24dea
|
|||
855bafee5b
|
|||
adde4e32c1
|
|||
527067146f
|
|||
93326907d2
|
|||
bcad87c6e0
|
|||
5d127d27ef
|
|||
2d6cb3ffe0
|
|||
e68920c0e2
|
|||
c5c15341b8
|
|||
cd4a7177d7
|
|||
daeef1bc4b
|
|||
ddae18f8b3
|
|||
8c8657fdd8
|
|||
c4b0200dc6
|
|||
38bafd7186
|
@ -1,3 +1,5 @@
|
|||||||
---
|
---
|
||||||
exclude_paths:
|
exclude_paths:
|
||||||
- 'galaxy.roles/'
|
- ".ansible/"
|
||||||
|
- "galaxy.roles/"
|
||||||
|
- "Taskfile.yml"
|
||||||
|
1
.gitignore
vendored
1
.gitignore
vendored
@ -5,6 +5,7 @@
|
|||||||
|
|
||||||
/galaxy.roles/
|
/galaxy.roles/
|
||||||
/ansible-vault-password-file
|
/ansible-vault-password-file
|
||||||
|
/temp
|
||||||
*.retry
|
*.retry
|
||||||
|
|
||||||
test_smtp.py
|
test_smtp.py
|
||||||
|
35
Taskfile.yml
35
Taskfile.yml
@ -12,8 +12,13 @@ vars:
|
|||||||
sh: 'yq .ungrouped.hosts.server.ansible_user {{.HOSTS_FILE}}'
|
sh: 'yq .ungrouped.hosts.server.ansible_user {{.HOSTS_FILE}}'
|
||||||
REMOTE_HOST:
|
REMOTE_HOST:
|
||||||
sh: 'yq .ungrouped.hosts.server.ansible_host {{.HOSTS_FILE}}'
|
sh: 'yq .ungrouped.hosts.server.ansible_host {{.HOSTS_FILE}}'
|
||||||
|
AUTHELIA_DOCKER: 'docker run --rm -v $PWD:/data authelia/authelia:4.39.4 authelia'
|
||||||
|
|
||||||
tasks:
|
tasks:
|
||||||
|
install-roles:
|
||||||
|
cmds:
|
||||||
|
- ansible-galaxy role install --role-file requirements.yml --force
|
||||||
|
|
||||||
ssh:
|
ssh:
|
||||||
cmds:
|
cmds:
|
||||||
- ssh {{.REMOTE_USER}}@{{.REMOTE_HOST}}
|
- ssh {{.REMOTE_USER}}@{{.REMOTE_HOST}}
|
||||||
@ -30,6 +35,36 @@ tasks:
|
|||||||
cmds:
|
cmds:
|
||||||
- ansible-vault encrypt vars/vars.yml
|
- ansible-vault encrypt vars/vars.yml
|
||||||
|
|
||||||
|
authelia-cli:
|
||||||
|
cmds:
|
||||||
|
- "{{.AUTHELIA_DOCKER}} {{.CLI_ARGS}}"
|
||||||
|
|
||||||
|
authelia-validate-config:
|
||||||
|
vars:
|
||||||
|
DEST_FILE: "temp/configuration.yml"
|
||||||
|
cmds:
|
||||||
|
- >
|
||||||
|
ansible localhost
|
||||||
|
--module-name template
|
||||||
|
--args "src=files/authelia/configuration.yml.j2 dest={{.DEST_FILE}}"
|
||||||
|
--extra-vars "@vars/secrets.yml"
|
||||||
|
- defer: rm -f {{.DEST_FILE}}
|
||||||
|
- >
|
||||||
|
{{.AUTHELIA_DOCKER}}
|
||||||
|
validate-config --config /data/{{.DEST_FILE}}
|
||||||
|
|
||||||
|
authelia-gen-random-string:
|
||||||
|
cmds:
|
||||||
|
- >
|
||||||
|
{{.AUTHELIA_DOCKER}}
|
||||||
|
crypto rand --length 32 --charset alphanumeric
|
||||||
|
|
||||||
|
authelia-gen-secret-and-hash:
|
||||||
|
cmds:
|
||||||
|
- >
|
||||||
|
{{.AUTHELIA_DOCKER}}
|
||||||
|
crypto hash generate pbkdf2 --variant sha512 --random --random.length 72 --random.charset rfc3986
|
||||||
|
|
||||||
format-py-files:
|
format-py-files:
|
||||||
cmds:
|
cmds:
|
||||||
- >-
|
- >-
|
||||||
|
3725
files/authelia/configuration.yml.j2
Normal file
3725
files/authelia/configuration.yml.j2
Normal file
File diff suppressed because it is too large
Load Diff
15
files/authelia/docker-compose.yml.j2
Normal file
15
files/authelia/docker-compose.yml.j2
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
services:
|
||||||
|
|
||||||
|
authelia_app:
|
||||||
|
container_name: 'authelia_app'
|
||||||
|
image: 'docker.io/authelia/authelia:4.39.4'
|
||||||
|
user: '{{ user_create_result.uid }}:{{ user_create_result.group }}'
|
||||||
|
restart: 'unless-stopped'
|
||||||
|
networks:
|
||||||
|
- "{{ web_proxy_network }}"
|
||||||
|
volumes:
|
||||||
|
- "{{ config_dir }}:/config"
|
||||||
|
|
||||||
|
networks:
|
||||||
|
{{ web_proxy_network }}:
|
||||||
|
external: true
|
37
files/authelia/users.yml
Normal file
37
files/authelia/users.yml
Normal file
@ -0,0 +1,37 @@
|
|||||||
|
$ANSIBLE_VAULT;1.1;AES256
|
||||||
|
33323463653739626134366261626263396338333966376262313263613131343962326432613263
|
||||||
|
6430616564313432666436376432383539626231616438330a646161313364353566373833353337
|
||||||
|
64633361306564646564663736663937303435356332316432666135353863393439663235646462
|
||||||
|
3136303031383835390a396531366636386133656366653835633833633733326561383066656464
|
||||||
|
31613933333731643065316130303561383563626636346633396266346332653234373732326535
|
||||||
|
39663765353938333835646563663633393835633163323435303164663261303661666435306239
|
||||||
|
34353264633736383565306336633565376436646536623835613330393466363935303031346664
|
||||||
|
63626465656435383162633761333131393934666632336539386435613362353135383538643836
|
||||||
|
66373261306139353134393839333539366531393163393266386531613732366431663865343134
|
||||||
|
64363933616338663966353431396133316561653366396130653232636561343739336265386339
|
||||||
|
38646238653436663531633465616164303633356233363433623038666465326339656238653233
|
||||||
|
36323162303233633935646132353835336364303833636563346535316166346533636536656665
|
||||||
|
64323030616665316133363739393364306462316135636630613262646436643062373138656431
|
||||||
|
35663334616239623534383564643738616264373762663034376332323637626337306639653830
|
||||||
|
65386339666465343931303933663561643664313364386662656663643336636264636333666435
|
||||||
|
66366531613538363233346137383462326334306534333564636232393931393433386664363036
|
||||||
|
39623134636331646536323531653063326231613363366562643561353939633062663132303035
|
||||||
|
38303265326136303633666566613966636133666336396133333033643434303138303065666463
|
||||||
|
36643765316134636133333937396332613233383932663265386264623133633364646237346465
|
||||||
|
32623965653662336335366639643765393636623236323036396538353666646132393636663536
|
||||||
|
65646638643236313762373135336430643731643961386264303134366633353934366431333430
|
||||||
|
34313362633836613166336437323835626537653237666139383230663835626630623933383834
|
||||||
|
32636136663830643661363663303136393733646133626538333836666135653936323832336433
|
||||||
|
64396234396430326334656561393264366263313730306631383037643135613765373861356561
|
||||||
|
37363933383238316232336564363364376637626630373963666262376165343838303530653764
|
||||||
|
64343937666365646666363939383662313334656236326566373565643637313434616261616635
|
||||||
|
35646131396432623534396133666239613036386332663038353531313935636139363136666562
|
||||||
|
62616234663935383262626235313337623332333733383035666633393965336535316234323561
|
||||||
|
37353563623138343339616565653465633633383563636631356333303435376536393634343031
|
||||||
|
63653062303432366230643333353634383061313135616533643935316263393366653335353964
|
||||||
|
36363135356365373064613338393261326265396330323930613538326330663532616163666564
|
||||||
|
39313631633434353938626637626462376139383536306531633733646331303030333238373161
|
||||||
|
36336364383939663132366461383264346631366566363638333738386235623264623331343738
|
||||||
|
34316436393363323165396430343163653837623035626236313663643038336666633535666462
|
||||||
|
33323566353062653964643362363233346264396365336637376661323730336437333031363830
|
||||||
|
38303962646561346262
|
@ -4,22 +4,28 @@ set -eu
|
|||||||
set -o pipefail
|
set -o pipefail
|
||||||
|
|
||||||
echo "Backup: perform gitea backup"
|
echo "Backup: perform gitea backup"
|
||||||
|
su --login gitea --command '/home/gitea/backup.sh'
|
||||||
|
|
||||||
su --login gitea -c '/home/gitea/gitea-dump.sh'
|
echo "Backup: perform outline backup"
|
||||||
mkdir -p {{ backup_directory }}/gitea
|
su --login outline --command '/home/outline/backup.sh'
|
||||||
mv /home/gitea/backups/* {{ backup_directory }}/gitea
|
|
||||||
|
|
||||||
echo "Backup: perform backup with gobackup"
|
echo "Backup: perform gramps backup"
|
||||||
|
su --login gramps --command '/home/gramps/backup.sh'
|
||||||
|
|
||||||
gobackup perform --config={{ backup_gobackup_config }}
|
echo "Backup: perform miniflux backup"
|
||||||
|
su --login miniflux --command '/home/miniflux/backup.sh'
|
||||||
|
|
||||||
|
echo "Backup: perform wakapi backup"
|
||||||
|
su --login wakapi --command '/home/wakapi/backup.sh'
|
||||||
|
|
||||||
echo "Backup: send backups to remote storage with retic"
|
echo "Backup: send backups to remote storage with retic"
|
||||||
|
|
||||||
restic-shell.sh backup --verbose {{ backup_directory }} \
|
restic-shell.sh backup --verbose /home/gitea/backups /home/outline/backups /home/gramps/backups /home/miniflux/backups /home/wakapi/backups \
|
||||||
&& restic-shell.sh check \
|
&& restic-shell.sh check \
|
||||||
&& restic-shell.sh forget --compact --prune --keep-daily 90 --keep-monthly 36 \
|
&& restic-shell.sh forget --compact --prune --keep-daily 90 --keep-monthly 36 \
|
||||||
&& restic-shell.sh check
|
&& restic-shell.sh check
|
||||||
|
|
||||||
|
|
||||||
echo "Backup: send notification"
|
echo "Backup: send notification"
|
||||||
|
|
||||||
curl -s -X POST 'https://api.telegram.org/bot{{ notifications_tg_bot_token }}/sendMessage' \
|
curl -s -X POST 'https://api.telegram.org/bot{{ notifications_tg_bot_token }}/sendMessage' \
|
||||||
@ -27,8 +33,5 @@ curl -s -X POST 'https://api.telegram.org/bot{{ notifications_tg_bot_token }}/se
|
|||||||
-d 'parse_mode=HTML' \
|
-d 'parse_mode=HTML' \
|
||||||
-d 'text=<b>{{ notifications_name }}</b>: бекап успешно завершен!'
|
-d 'text=<b>{{ notifications_name }}</b>: бекап успешно завершен!'
|
||||||
|
|
||||||
echo -e "\nRemove old files"
|
|
||||||
|
|
||||||
keep-files.py {{ backup_directory }}/gitea --keep 2
|
|
||||||
|
|
||||||
echo -e "\nBackup: done"
|
echo -e "\nBackup: done"
|
@ -1,32 +0,0 @@
|
|||||||
# https://gobackup.github.io/configuration
|
|
||||||
|
|
||||||
models:
|
|
||||||
|
|
||||||
gramps:
|
|
||||||
compress_with:
|
|
||||||
type: 'tgz'
|
|
||||||
storages:
|
|
||||||
local:
|
|
||||||
type: 'local'
|
|
||||||
path: '{{ (backup_directory, "gramps") | path_join }}'
|
|
||||||
keep: 2
|
|
||||||
databases:
|
|
||||||
users:
|
|
||||||
type: sqlite
|
|
||||||
path: /home/major/applications/gramps/data/gramps_users/users.sqlite
|
|
||||||
search_index:
|
|
||||||
type: sqlite
|
|
||||||
path: /home/major/applications/gramps/data/gramps_index/search_index.db
|
|
||||||
sqlite:
|
|
||||||
type: sqlite
|
|
||||||
path: /home/major/applications/gramps/data/gramps_db/59a0f3d6-1c3d-4410-8c1d-1c9c6689659f/sqlite.db
|
|
||||||
undo:
|
|
||||||
type: sqlite
|
|
||||||
path: /home/major/applications/gramps/data/gramps_db/59a0f3d6-1c3d-4410-8c1d-1c9c6689659f/undo.db
|
|
||||||
archive:
|
|
||||||
includes:
|
|
||||||
- /home/major/applications/gramps
|
|
||||||
excludes:
|
|
||||||
- /home/major/applications/gramps/data/gramps_cache
|
|
||||||
- /home/major/applications/gramps/data/gramps_thumb_cache
|
|
||||||
- /home/major/applications/gramps/data/gramps_tmp
|
|
93
files/caddyproxy/Caddyfile.j2
Normal file
93
files/caddyproxy/Caddyfile.j2
Normal file
@ -0,0 +1,93 @@
|
|||||||
|
# -------------------------------------------------------------------
|
||||||
|
# Global options
|
||||||
|
# -------------------------------------------------------------------
|
||||||
|
{
|
||||||
|
grace_period 15s
|
||||||
|
|
||||||
|
admin :2019
|
||||||
|
|
||||||
|
# Enable metrics in Prometheus format
|
||||||
|
# https://caddyserver.com/docs/metrics
|
||||||
|
metrics
|
||||||
|
}
|
||||||
|
|
||||||
|
# -------------------------------------------------------------------
|
||||||
|
# Applications
|
||||||
|
# -------------------------------------------------------------------
|
||||||
|
|
||||||
|
vakhrushev.me {
|
||||||
|
tls anwinged@ya.ru
|
||||||
|
|
||||||
|
reverse_proxy {
|
||||||
|
to homepage_app:80
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
auth.vakhrushev.me {
|
||||||
|
tls anwinged@ya.ru
|
||||||
|
|
||||||
|
reverse_proxy authelia_app:9091
|
||||||
|
}
|
||||||
|
|
||||||
|
status.vakhrushev.me, :29999 {
|
||||||
|
tls anwinged@ya.ru
|
||||||
|
|
||||||
|
forward_auth authelia_app:9091 {
|
||||||
|
uri /api/authz/forward-auth
|
||||||
|
copy_headers Remote-User Remote-Groups Remote-Email Remote-Name
|
||||||
|
}
|
||||||
|
|
||||||
|
reverse_proxy netdata:19999
|
||||||
|
}
|
||||||
|
|
||||||
|
git.vakhrushev.me {
|
||||||
|
tls anwinged@ya.ru
|
||||||
|
|
||||||
|
reverse_proxy {
|
||||||
|
to gitea_app:3000
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
outline.vakhrushev.me {
|
||||||
|
tls anwinged@ya.ru
|
||||||
|
|
||||||
|
reverse_proxy {
|
||||||
|
to outline_app:3000
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
gramps.vakhrushev.me {
|
||||||
|
tls anwinged@ya.ru
|
||||||
|
|
||||||
|
reverse_proxy {
|
||||||
|
to gramps_app:5000
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
miniflux.vakhrushev.me {
|
||||||
|
tls anwinged@ya.ru
|
||||||
|
|
||||||
|
reverse_proxy {
|
||||||
|
to miniflux_app:8080
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
wakapi.vakhrushev.me {
|
||||||
|
tls anwinged@ya.ru
|
||||||
|
|
||||||
|
reverse_proxy {
|
||||||
|
to wakapi_app:3000
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
rssbridge.vakhrushev.me {
|
||||||
|
tls anwinged@ya.ru
|
||||||
|
|
||||||
|
forward_auth authelia_app:9091 {
|
||||||
|
uri /api/authz/forward-auth
|
||||||
|
copy_headers Remote-User Remote-Groups Remote-Email Remote-Name
|
||||||
|
}
|
||||||
|
|
||||||
|
reverse_proxy rssbridge_app:80
|
||||||
|
}
|
||||||
|
}
|
22
files/caddyproxy/docker-compose.yml.j2
Normal file
22
files/caddyproxy/docker-compose.yml.j2
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
services:
|
||||||
|
|
||||||
|
{{ service_name }}:
|
||||||
|
image: caddy:2.10.0
|
||||||
|
restart: unless-stopped
|
||||||
|
container_name: {{ service_name }}
|
||||||
|
ports:
|
||||||
|
- "80:80"
|
||||||
|
- "443:443"
|
||||||
|
- "443:443/udp"
|
||||||
|
cap_add:
|
||||||
|
- NET_ADMIN
|
||||||
|
volumes:
|
||||||
|
- {{ caddy_file_dir }}:/etc/caddy
|
||||||
|
- {{ data_dir }}:/data
|
||||||
|
- {{ config_dir }}:/config
|
||||||
|
networks:
|
||||||
|
- "{{ web_proxy_network }}"
|
||||||
|
|
||||||
|
networks:
|
||||||
|
{{ web_proxy_network }}:
|
||||||
|
external: true
|
@ -1,25 +0,0 @@
|
|||||||
$ANSIBLE_VAULT;1.1;AES256
|
|
||||||
36373937313831396330393762313931643536363765353936333166376465343033376564613538
|
|
||||||
3235356131646564393664376535646561323435363330660a353632613334633461383562306662
|
|
||||||
37373439373636383834383464316337656531626663393830323332613136323438313762656435
|
|
||||||
6338353136306338640a636539363766663030356432663361636438386538323238373235663766
|
|
||||||
37393035356137653763373364623836346439663062313061346537353634306138376231633635
|
|
||||||
30363465663836373830366231636265663837646137313764316364623637623333346636363934
|
|
||||||
33666164343832653536303262663635616632663561633739636561333964653862313131613232
|
|
||||||
39316239376566633964633064393532613935306161666666323337343130393861306532623666
|
|
||||||
39653463323532333932646262663862313961393430306663643866623865346666313731366331
|
|
||||||
32663262636132663238313630373937663936326532643730613161376565653263633935393363
|
|
||||||
63373163346566363639396432653132646334643031323532613238666531363630353266303139
|
|
||||||
31613138303131343364343438663762343936393165356235646239343039396637643666653065
|
|
||||||
31363163623863613533663366303664623134396134393765636435633464373731653563646537
|
|
||||||
39373766626338646564356463623531373337303861383862613966323132656639326533356533
|
|
||||||
38346263326361656563386333663531663232623436653866383865393964353363353563653532
|
|
||||||
65343130383262386262393634636338313732623565666531303636303433333638323230346565
|
|
||||||
61633837373531343530383238396162373632623135333263323234623833383731336463333063
|
|
||||||
62656533636237303962653238653934346430366533636436646264306461323639666665623839
|
|
||||||
32643637623630613863323335666138303538313236343932386461346433656432626433663365
|
|
||||||
38376666623839393630343637386336623334623064383131316331333564363934636662633630
|
|
||||||
31363337393339643738306363306538373133626564613765643138666237303330613036666537
|
|
||||||
61363838353736613531613436313730313936363564303464346661376137303133633062613932
|
|
||||||
36383631303739306264386663333338666235346339623338333663386663303439363362376239
|
|
||||||
35626136646634363430
|
|
21
files/gitea/backup.sh.j2
Normal file
21
files/gitea/backup.sh.j2
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
set -eu
|
||||||
|
set -o pipefail
|
||||||
|
|
||||||
|
echo "Gitea: backup data with gitea dump"
|
||||||
|
|
||||||
|
(cd "{{ base_dir }}" && \
|
||||||
|
docker compose exec \
|
||||||
|
-u "{{ user_create_result.uid }}:{{ user_create_result.group }}" \
|
||||||
|
-w /backups gitea_app \
|
||||||
|
gitea dump -c /data/gitea/conf/app.ini \
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
|
echo "Gitea: remove old backups"
|
||||||
|
|
||||||
|
keep-files.py "{{ backups_dir }}" --keep 3
|
||||||
|
|
||||||
|
|
||||||
|
echo "Gitea: done."
|
@ -1,17 +1,19 @@
|
|||||||
services:
|
services:
|
||||||
|
|
||||||
gitea_app:
|
gitea_app:
|
||||||
image: gitea/gitea:1.23.7
|
image: gitea/gitea:1.24.2
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
container_name: gitea_app
|
container_name: gitea_app
|
||||||
ports:
|
ports:
|
||||||
- "127.0.0.1:{{ gitea_port }}:3000"
|
- "127.0.0.1:{{ gitea_port }}:3000"
|
||||||
- "2222:22"
|
- "2222:22"
|
||||||
volumes:
|
volumes:
|
||||||
- ./data:/data
|
- {{ data_dir }}:/data
|
||||||
- ./backups:/backups
|
- {{ backups_dir }}:/backups
|
||||||
- /etc/timezone:/etc/timezone:ro
|
- /etc/timezone:/etc/timezone:ro
|
||||||
- /etc/localtime:/etc/localtime:ro
|
- /etc/localtime:/etc/localtime:ro
|
||||||
|
networks:
|
||||||
|
- "{{ web_proxy_network }}"
|
||||||
environment:
|
environment:
|
||||||
- "USER_UID=${USER_UID}"
|
- "USER_UID=${USER_UID}"
|
||||||
- "USER_GID=${USER_GID}"
|
- "USER_GID=${USER_GID}"
|
||||||
@ -25,3 +27,7 @@ services:
|
|||||||
- "GITEA__mailer__USER={{ postbox_user }}"
|
- "GITEA__mailer__USER={{ postbox_user }}"
|
||||||
- "GITEA__mailer__PASSWD={{ postbox_pass }}"
|
- "GITEA__mailer__PASSWD={{ postbox_pass }}"
|
||||||
- "GITEA__mailer__FROM=gitea@vakhrushev.me"
|
- "GITEA__mailer__FROM=gitea@vakhrushev.me"
|
||||||
|
|
||||||
|
networks:
|
||||||
|
{{ web_proxy_network }}:
|
||||||
|
external: true
|
||||||
|
@ -1,13 +0,0 @@
|
|||||||
#!/usr/bin/env bash
|
|
||||||
|
|
||||||
set -eu
|
|
||||||
set -o pipefail
|
|
||||||
|
|
||||||
echo "Gitea: backup data with gitea dump"
|
|
||||||
|
|
||||||
(cd {{ base_dir }} && docker compose exec -u "{{ user_create_result.uid }}:{{ user_create_result.group }}" -w /backups gitea_app gitea dump -c /data/gitea/conf/app.ini)
|
|
||||||
|
|
||||||
|
|
||||||
echo "Gitea: remove old backups"
|
|
||||||
|
|
||||||
keep-files.py {{ backups_dir }} --keep 2
|
|
10
files/gramps/backup.sh.j2
Normal file
10
files/gramps/backup.sh.j2
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
set -eu
|
||||||
|
set -o pipefail
|
||||||
|
|
||||||
|
echo "Gramps: backup data with gobackups"
|
||||||
|
|
||||||
|
(cd "{{ base_dir }}" && gobackup perform --config "{{ gobackup_config }}")
|
||||||
|
|
||||||
|
echo "Gramps: done."
|
@ -3,13 +3,22 @@
|
|||||||
services:
|
services:
|
||||||
|
|
||||||
gramps_app: &gramps_app
|
gramps_app: &gramps_app
|
||||||
image: ghcr.io/gramps-project/grampsweb:v25.4.1
|
image: ghcr.io/gramps-project/grampsweb:25.7.0
|
||||||
container_name: gramps_app
|
container_name: gramps_app
|
||||||
depends_on:
|
depends_on:
|
||||||
- gramps_redis
|
- gramps_redis
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
ports:
|
networks:
|
||||||
- "127.0.0.1:{{ gramps_port }}:5000" # host:docker
|
- "gramps_network"
|
||||||
|
- "{{ web_proxy_network }}"
|
||||||
|
volumes:
|
||||||
|
- "{{ (data_dir, 'gramps_db') | path_join }}:/root/.gramps/grampsdb" # persist Gramps database
|
||||||
|
- "{{ (data_dir, 'gramps_users') | path_join }}:/app/users" # persist user database
|
||||||
|
- "{{ (data_dir, 'gramps_index') | path_join }}:/app/indexdir" # persist search index
|
||||||
|
- "{{ (data_dir, 'gramps_thumb_cache') | path_join }}:/app/thumbnail_cache" # persist thumbnails
|
||||||
|
- "{{ (data_dir, 'gramps_cache') | path_join }}:/app/cache" # persist export and report caches
|
||||||
|
- "{{ (data_dir, 'gramps_secret') | path_join }}:/app/secret" # persist flask secret
|
||||||
|
- "{{ (data_dir, 'gramps_media') | path_join }}:/app/media" # persist media files
|
||||||
environment:
|
environment:
|
||||||
GRAMPSWEB_TREE: "Gramps" # will create a new tree if not exists
|
GRAMPSWEB_TREE: "Gramps" # will create a new tree if not exists
|
||||||
GRAMPSWEB_SECRET_KEY: "{{ gramps_secret_key }}"
|
GRAMPSWEB_SECRET_KEY: "{{ gramps_secret_key }}"
|
||||||
@ -18,27 +27,22 @@ services:
|
|||||||
GRAMPSWEB_CELERY_CONFIG__broker_url: "redis://gramps_redis:6379/0"
|
GRAMPSWEB_CELERY_CONFIG__broker_url: "redis://gramps_redis:6379/0"
|
||||||
GRAMPSWEB_CELERY_CONFIG__result_backend: "redis://gramps_redis:6379/0"
|
GRAMPSWEB_CELERY_CONFIG__result_backend: "redis://gramps_redis:6379/0"
|
||||||
GRAMPSWEB_RATELIMIT_STORAGE_URI: "redis://gramps_redis:6379/1"
|
GRAMPSWEB_RATELIMIT_STORAGE_URI: "redis://gramps_redis:6379/1"
|
||||||
|
GUNICORN_NUM_WORKERS: 2
|
||||||
|
|
||||||
|
# Email options
|
||||||
GRAMPSWEB_EMAIL_HOST: "{{ postbox_host }}"
|
GRAMPSWEB_EMAIL_HOST: "{{ postbox_host }}"
|
||||||
GRAMPSWEB_EMAIL_PORT: "{{ postbox_port }}"
|
GRAMPSWEB_EMAIL_PORT: "{{ postbox_port }}"
|
||||||
GRAMPSWEB_EMAIL_HOST_USER: "{{ postbox_user }}"
|
GRAMPSWEB_EMAIL_HOST_USER: "{{ postbox_user }}"
|
||||||
GRAMPSWEB_EMAIL_HOST_PASSWORD: "{{ postbox_pass }}"
|
GRAMPSWEB_EMAIL_HOST_PASSWORD: "{{ postbox_pass }}"
|
||||||
GRAMPSWEB_EMAIL_USE_TLS: "false"
|
GRAMPSWEB_EMAIL_USE_TLS: "false"
|
||||||
GRAMPSWEB_DEFAULT_FROM_EMAIL: "gramps@vakhrushev.me"
|
GRAMPSWEB_DEFAULT_FROM_EMAIL: "gramps@vakhrushev.me"
|
||||||
GUNICORN_NUM_WORKERS: 2
|
|
||||||
# media storage at s3
|
# media storage at s3
|
||||||
GRAMPSWEB_MEDIA_BASE_DIR: "s3://av-gramps-media-storage"
|
GRAMPSWEB_MEDIA_BASE_DIR: "s3://av-gramps-media-storage"
|
||||||
AWS_ENDPOINT_URL: "{{ gramps_s3_endpoint }}"
|
AWS_ENDPOINT_URL: "{{ gramps_s3_endpoint }}"
|
||||||
AWS_ACCESS_KEY_ID: "{{ gramps_s3_access_key_id }}"
|
AWS_ACCESS_KEY_ID: "{{ gramps_s3_access_key_id }}"
|
||||||
AWS_SECRET_ACCESS_KEY: "{{ gramps_s3_secret_access_key }}"
|
AWS_SECRET_ACCESS_KEY: "{{ gramps_s3_secret_access_key }}"
|
||||||
AWS_DEFAULT_REGION: "{{ gramps_s3_region }}"
|
AWS_DEFAULT_REGION: "{{ gramps_s3_region }}"
|
||||||
volumes:
|
|
||||||
- ./data/gramps_users:/app/users # persist user database
|
|
||||||
- ./data/gramps_index:/app/indexdir # persist search index
|
|
||||||
- ./data/gramps_thumb_cache:/app/thumbnail_cache # persist thumbnails
|
|
||||||
- ./data/gramps_cache:/app/cache # persist export and report caches
|
|
||||||
- ./data/gramps_secret:/app/secret # persist flask secret
|
|
||||||
- ./data/gramps_db:/root/.gramps/grampsdb # persist Gramps database
|
|
||||||
- ./data/gramps_media:/app/media # persist media files
|
|
||||||
|
|
||||||
gramps_celery:
|
gramps_celery:
|
||||||
<<: *gramps_app # YAML merge key copying the entire grampsweb service config
|
<<: *gramps_app # YAML merge key copying the entire grampsweb service config
|
||||||
@ -47,9 +51,19 @@ services:
|
|||||||
- gramps_redis
|
- gramps_redis
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
ports: []
|
ports: []
|
||||||
|
networks:
|
||||||
|
- "gramps_network"
|
||||||
command: celery -A gramps_webapi.celery worker --loglevel=INFO --concurrency=2
|
command: celery -A gramps_webapi.celery worker --loglevel=INFO --concurrency=2
|
||||||
|
|
||||||
gramps_redis:
|
gramps_redis:
|
||||||
image: valkey/valkey:8.1.1-alpine
|
image: valkey/valkey:8.1.1-alpine
|
||||||
container_name: gramps_redis
|
container_name: gramps_redis
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
|
networks:
|
||||||
|
- "gramps_network"
|
||||||
|
|
||||||
|
networks:
|
||||||
|
gramps_network:
|
||||||
|
driver: bridge
|
||||||
|
{{ web_proxy_network }}:
|
||||||
|
external: true
|
||||||
|
32
files/gramps/gobackup.yml.j2
Normal file
32
files/gramps/gobackup.yml.j2
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
# https://gobackup.github.io/configuration
|
||||||
|
|
||||||
|
models:
|
||||||
|
|
||||||
|
gramps:
|
||||||
|
compress_with:
|
||||||
|
type: 'tgz'
|
||||||
|
storages:
|
||||||
|
local:
|
||||||
|
type: 'local'
|
||||||
|
path: '{{ backups_dir }}'
|
||||||
|
keep: 3
|
||||||
|
databases:
|
||||||
|
users:
|
||||||
|
type: sqlite
|
||||||
|
path: "{{ (data_dir, 'gramps_users/users.sqlite') | path_join }}"
|
||||||
|
search_index:
|
||||||
|
type: sqlite
|
||||||
|
path: "{{ (data_dir, 'gramps_index/search_index.db') | path_join }}"
|
||||||
|
sqlite:
|
||||||
|
type: sqlite
|
||||||
|
path: "{{ (data_dir, 'gramps_db/59a0f3d6-1c3d-4410-8c1d-1c9c6689659f/sqlite.db') | path_join }}"
|
||||||
|
undo:
|
||||||
|
type: sqlite
|
||||||
|
path: "{{ (data_dir, 'gramps_db/59a0f3d6-1c3d-4410-8c1d-1c9c6689659f/undo.db') | path_join }}"
|
||||||
|
archive:
|
||||||
|
includes:
|
||||||
|
- "{{ data_dir }}"
|
||||||
|
excludes:
|
||||||
|
- "{{ (data_dir, 'gramps_cache') | path_join }}"
|
||||||
|
- "{{ (data_dir, 'gramps_thumb_cache') | path_join }}"
|
||||||
|
- "{{ (data_dir, 'gramps_tmp') | path_join }}"
|
@ -1,7 +0,0 @@
|
|||||||
services:
|
|
||||||
homepage_app:
|
|
||||||
image: "${WEB_SERVICE_IMAGE}"
|
|
||||||
container_name: homepage_app
|
|
||||||
ports:
|
|
||||||
- "127.0.0.1:${WEB_SERVICE_PORT}:80"
|
|
||||||
restart: unless-stopped
|
|
14
files/homepage/docker-compose.yml.j2
Normal file
14
files/homepage/docker-compose.yml.j2
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
services:
|
||||||
|
homepage_app:
|
||||||
|
image: "{{ registry_homepage_web_image }}"
|
||||||
|
container_name: homepage_app
|
||||||
|
restart: unless-stopped
|
||||||
|
ports:
|
||||||
|
- "127.0.0.1:{{ homepage_port }}:80"
|
||||||
|
networks:
|
||||||
|
- "{{ web_proxy_network }}"
|
||||||
|
|
||||||
|
networks:
|
||||||
|
{{ web_proxy_network }}:
|
||||||
|
external: true
|
||||||
|
|
@ -32,7 +32,7 @@ def main():
|
|||||||
sorted_files = sorted(files)
|
sorted_files = sorted(files)
|
||||||
|
|
||||||
# Identify files to delete
|
# Identify files to delete
|
||||||
to_delete = sorted_files[: -args.keep] if args.keep > 0 else sorted_files.copy()
|
to_delete = sorted_files[:-args.keep] if args.keep > 0 else sorted_files.copy()
|
||||||
|
|
||||||
# Delete files and print results
|
# Delete files and print results
|
||||||
for filename in to_delete:
|
for filename in to_delete:
|
||||||
|
@ -1,23 +0,0 @@
|
|||||||
# Images: https://quay.io/repository/keycloak/keycloak?tab=tags&tag=latest
|
|
||||||
# Configuration: https://www.keycloak.org/server/all-config
|
|
||||||
|
|
||||||
# NB
|
|
||||||
# - На проде были проблемы с правами к директории data, пришлось выдать 777
|
|
||||||
# - Переменную KC_HOSTNAME_ADMIN_URL нужно указать вместе с KC_HOSTNAME_URL, иначе будут ошибки 403
|
|
||||||
|
|
||||||
services:
|
|
||||||
|
|
||||||
keycloak_app:
|
|
||||||
image: quay.io/keycloak/keycloak:24.0.4
|
|
||||||
container_name: keycloak_app
|
|
||||||
command: ["start-dev"]
|
|
||||||
restart: unless-stopped
|
|
||||||
environment:
|
|
||||||
KEYCLOAK_ADMIN: "{{ keycloak_admin_login }}"
|
|
||||||
KEYCLOAK_ADMIN_PASSWORD: "{{ keycloak_admin_password }}"
|
|
||||||
KC_HOSTNAME_URL: "https://kk.vakhrushev.me"
|
|
||||||
KC_HOSTNAME_ADMIN_URL: "https://kk.vakhrushev.me"
|
|
||||||
ports:
|
|
||||||
- "127.0.0.1:{{ keycloak_port }}:8080"
|
|
||||||
volumes:
|
|
||||||
- "./data:/opt/keycloak/data"
|
|
25
files/miniflux/backup.sh.j2
Normal file
25
files/miniflux/backup.sh.j2
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
set -eu
|
||||||
|
set -o pipefail
|
||||||
|
|
||||||
|
TIMESTAMP=$(date +%Y%m%d_%H%M%S)
|
||||||
|
BACKUP_FILE="miniflux_postgres_${TIMESTAMP}.sql.gz"
|
||||||
|
|
||||||
|
echo "miniflux: backing up postgresql database"
|
||||||
|
|
||||||
|
docker compose --file "{{ base_dir }}/docker-compose.yml" exec \
|
||||||
|
miniflux_postgres \
|
||||||
|
pg_dump \
|
||||||
|
-U "{{ miniflux_postgres_user }}" \
|
||||||
|
"{{ miniflux_postgres_database }}" \
|
||||||
|
| gzip > "{{ postgres_backups_dir }}/${BACKUP_FILE}"
|
||||||
|
|
||||||
|
echo "miniflux: PostgreSQL backup saved to {{ postgres_backups_dir }}/${BACKUP_FILE}"
|
||||||
|
|
||||||
|
echo "miniflux: removing old backups"
|
||||||
|
|
||||||
|
# Keep only the 3 most recent backups
|
||||||
|
keep-files.py "{{ postgres_backups_dir }}" --keep 3
|
||||||
|
|
||||||
|
echo "miniflux: backup completed successfully."
|
52
files/miniflux/docker-compose.yml.j2
Normal file
52
files/miniflux/docker-compose.yml.j2
Normal file
@ -0,0 +1,52 @@
|
|||||||
|
# See sample https://miniflux.app/docs/docker.html#docker-compose
|
||||||
|
# See env https://miniflux.app/docs/configuration.html
|
||||||
|
|
||||||
|
services:
|
||||||
|
miniflux_app:
|
||||||
|
image: miniflux/miniflux:2.2.10
|
||||||
|
container_name: miniflux_app
|
||||||
|
depends_on:
|
||||||
|
miniflux_postgres:
|
||||||
|
condition: service_healthy
|
||||||
|
networks:
|
||||||
|
- "miniflux_network"
|
||||||
|
- "{{ web_proxy_network }}"
|
||||||
|
environment:
|
||||||
|
- DATABASE_URL=postgres://{{ miniflux_postgres_user }}:{{ miniflux_postgres_password }}@miniflux_postgres/{{ miniflux_postgres_database }}?sslmode=disable
|
||||||
|
- RUN_MIGRATIONS=1
|
||||||
|
- CREATE_ADMIN=1
|
||||||
|
- ADMIN_USERNAME={{ miniflux_admin_user }}
|
||||||
|
- ADMIN_PASSWORD={{ miniflux_admin_password }}
|
||||||
|
- BASE_URL=https://miniflux.vakhrushev.me
|
||||||
|
- DISABLE_LOCAL_AUTH=1
|
||||||
|
- OAUTH2_OIDC_DISCOVERY_ENDPOINT=https://auth.vakhrushev.me
|
||||||
|
- OAUTH2_CLIENT_ID={{ miniflux_oidc_client_id }}
|
||||||
|
- OAUTH2_CLIENT_SECRET={{ miniflux_oidc_client_secret }}
|
||||||
|
- OAUTH2_OIDC_PROVIDER_NAME=Authelia
|
||||||
|
- OAUTH2_PROVIDER=oidc
|
||||||
|
- OAUTH2_REDIRECT_URL=https://miniflux.vakhrushev.me/oauth2/oidc/callback
|
||||||
|
- OAUTH2_USER_CREATION=1
|
||||||
|
- METRICS_COLLECTOR=1
|
||||||
|
- METRICS_ALLOWED_NETWORKS=0.0.0.0/0
|
||||||
|
|
||||||
|
miniflux_postgres:
|
||||||
|
image: postgres:16.3-bookworm
|
||||||
|
container_name: miniflux_postgres
|
||||||
|
environment:
|
||||||
|
- POSTGRES_USER={{ miniflux_postgres_user }}
|
||||||
|
- POSTGRES_PASSWORD={{ miniflux_postgres_password }}
|
||||||
|
- POSTGRES_DB={{ miniflux_postgres_database }}
|
||||||
|
networks:
|
||||||
|
- "miniflux_network"
|
||||||
|
volumes:
|
||||||
|
- {{ postgres_data_dir }}:/var/lib/postgresql/data
|
||||||
|
healthcheck:
|
||||||
|
test: ["CMD", "pg_isready", "-U", "miniflux"]
|
||||||
|
interval: 10s
|
||||||
|
start_period: 30s
|
||||||
|
|
||||||
|
networks:
|
||||||
|
miniflux_network:
|
||||||
|
driver: bridge
|
||||||
|
{{ web_proxy_network }}:
|
||||||
|
external: true
|
37
files/netdata/docker-compose.yml.j2
Normal file
37
files/netdata/docker-compose.yml.j2
Normal file
@ -0,0 +1,37 @@
|
|||||||
|
|
||||||
|
services:
|
||||||
|
|
||||||
|
netdata:
|
||||||
|
image: netdata/netdata:v2.5.4
|
||||||
|
container_name: netdata
|
||||||
|
restart: unless-stopped
|
||||||
|
cap_add:
|
||||||
|
- SYS_PTRACE
|
||||||
|
- SYS_ADMIN
|
||||||
|
security_opt:
|
||||||
|
- apparmor:unconfined
|
||||||
|
networks:
|
||||||
|
- "{{ web_proxy_network }}"
|
||||||
|
volumes:
|
||||||
|
- "{{ config_dir }}:/etc/netdata"
|
||||||
|
- "{{ (data_dir, 'lib') | path_join }}:/var/lib/netdata"
|
||||||
|
- "{{ (data_dir, 'cache') | path_join }}:/var/cache/netdata"
|
||||||
|
# Netdata system volumes
|
||||||
|
- "/:/host/root:ro,rslave"
|
||||||
|
- "/etc/group:/host/etc/group:ro"
|
||||||
|
- "/etc/localtime:/etc/localtime:ro"
|
||||||
|
- "/etc/os-release:/host/etc/os-release:ro"
|
||||||
|
- "/etc/passwd:/host/etc/passwd:ro"
|
||||||
|
- "/proc:/host/proc:ro"
|
||||||
|
- "/run/dbus:/run/dbus:ro"
|
||||||
|
- "/sys:/host/sys:ro"
|
||||||
|
- "/var/log:/host/var/log:ro"
|
||||||
|
- "/var/run:/host/var/run:ro"
|
||||||
|
- "/var/run/docker.sock:/var/run/docker.sock:ro"
|
||||||
|
environment:
|
||||||
|
PGID: "{{ netdata_docker_group_output.stdout | default(999) }}"
|
||||||
|
NETDATA_EXTRA_DEB_PACKAGES: "fail2ban"
|
||||||
|
|
||||||
|
networks:
|
||||||
|
{{ web_proxy_network }}:
|
||||||
|
external: true
|
3
files/netdata/go.d/fail2ban.conf
Normal file
3
files/netdata/go.d/fail2ban.conf
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
jobs:
|
||||||
|
- name: fail2ban
|
||||||
|
update_every: 5 # Collect Fail2Ban jails statistics every 5 seconds
|
22
files/netdata/go.d/prometheus.conf
Normal file
22
files/netdata/go.d/prometheus.conf
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
update_every: 5
|
||||||
|
autodetection_retry: 0
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
|
||||||
|
- name: caddyproxy
|
||||||
|
url: http://caddyproxy:2019/metrics
|
||||||
|
selector:
|
||||||
|
allow:
|
||||||
|
- "caddy_http_*"
|
||||||
|
|
||||||
|
- name: authelia
|
||||||
|
url: http://authelia_app:9959/metrics
|
||||||
|
selector:
|
||||||
|
allow:
|
||||||
|
- "authelia_*"
|
||||||
|
|
||||||
|
- name: miniflux
|
||||||
|
url: http://miniflux_app:8080/metrics
|
||||||
|
selector:
|
||||||
|
allow:
|
||||||
|
- "miniflux_*"
|
687
files/netdata/netdata.conf.j2
Normal file
687
files/netdata/netdata.conf.j2
Normal file
@ -0,0 +1,687 @@
|
|||||||
|
# netdata configuration
|
||||||
|
#
|
||||||
|
# You can download the latest version of this file, using:
|
||||||
|
#
|
||||||
|
# wget -O /etc/netdata/netdata.conf http://localhost:19999/netdata.conf
|
||||||
|
# or
|
||||||
|
# curl -o /etc/netdata/netdata.conf http://localhost:19999/netdata.conf
|
||||||
|
#
|
||||||
|
# You can uncomment and change any of the options below.
|
||||||
|
# The value shown in the commented settings, is the default value.
|
||||||
|
#
|
||||||
|
|
||||||
|
# global netdata configuration
|
||||||
|
|
||||||
|
[global]
|
||||||
|
# run as user = netdata
|
||||||
|
# host access prefix = /host
|
||||||
|
# pthread stack size = 8MiB
|
||||||
|
# cpu cores = 2
|
||||||
|
# libuv worker threads = 16
|
||||||
|
# profile = standalone
|
||||||
|
hostname = {{ host_name }}
|
||||||
|
# glibc malloc arena max for plugins = 1
|
||||||
|
# glibc malloc arena max for netdata = 1
|
||||||
|
# crash reports = all
|
||||||
|
# timezone = Etc/UTC
|
||||||
|
# OOM score = 0
|
||||||
|
# process scheduling policy = keep
|
||||||
|
# is ephemeral node = no
|
||||||
|
# has unstable connection = no
|
||||||
|
|
||||||
|
[db]
|
||||||
|
# enable replication = yes
|
||||||
|
# replication period = 1d
|
||||||
|
# replication step = 1h
|
||||||
|
# replication threads = 1
|
||||||
|
# replication prefetch = 10
|
||||||
|
# update every = 1s
|
||||||
|
# db = dbengine
|
||||||
|
# memory deduplication (ksm) = auto
|
||||||
|
# cleanup orphan hosts after = 1h
|
||||||
|
# cleanup ephemeral hosts after = off
|
||||||
|
# cleanup obsolete charts after = 1h
|
||||||
|
# gap when lost iterations above = 1
|
||||||
|
# dbengine page type = gorilla
|
||||||
|
# dbengine page cache size = 32MiB
|
||||||
|
# dbengine extent cache size = off
|
||||||
|
# dbengine enable journal integrity check = no
|
||||||
|
# dbengine use all ram for caches = no
|
||||||
|
# dbengine out of memory protection = 391.99MiB
|
||||||
|
# dbengine use direct io = yes
|
||||||
|
# dbengine journal v2 unmount time = 2m
|
||||||
|
# dbengine pages per extent = 109
|
||||||
|
# storage tiers = 3
|
||||||
|
# dbengine tier backfill = new
|
||||||
|
# dbengine tier 1 update every iterations = 60
|
||||||
|
# dbengine tier 2 update every iterations = 60
|
||||||
|
# dbengine tier 0 retention size = 1024MiB
|
||||||
|
# dbengine tier 0 retention time = 14d
|
||||||
|
# dbengine tier 1 retention size = 1024MiB
|
||||||
|
# dbengine tier 1 retention time = 3mo
|
||||||
|
# dbengine tier 2 retention size = 1024MiB
|
||||||
|
# dbengine tier 2 retention time = 2y
|
||||||
|
# extreme cardinality protection = yes
|
||||||
|
# extreme cardinality keep instances = 1000
|
||||||
|
# extreme cardinality min ephemerality = 50
|
||||||
|
|
||||||
|
[directories]
|
||||||
|
# config = /etc/netdata
|
||||||
|
# stock config = /usr/lib/netdata/conf.d
|
||||||
|
# log = /var/log/netdata
|
||||||
|
# web = /usr/share/netdata/web
|
||||||
|
# cache = /var/cache/netdata
|
||||||
|
# lib = /var/lib/netdata
|
||||||
|
# cloud.d = /var/lib/netdata/cloud.d
|
||||||
|
# plugins = "/usr/libexec/netdata/plugins.d" "/etc/netdata/custom-plugins.d"
|
||||||
|
# registry = /var/lib/netdata/registry
|
||||||
|
# home = /etc/netdata
|
||||||
|
# stock health config = /usr/lib/netdata/conf.d/health.d
|
||||||
|
# health config = /etc/netdata/health.d
|
||||||
|
|
||||||
|
[logs]
|
||||||
|
# facility = daemon
|
||||||
|
# logs flood protection period = 1m
|
||||||
|
# logs to trigger flood protection = 1000
|
||||||
|
# level = info
|
||||||
|
# debug = /var/log/netdata/debug.log
|
||||||
|
# daemon = /var/log/netdata/daemon.log
|
||||||
|
# collector = /var/log/netdata/collector.log
|
||||||
|
# access = /var/log/netdata/access.log
|
||||||
|
# health = /var/log/netdata/health.log
|
||||||
|
# debug flags = 0x0000000000000000
|
||||||
|
|
||||||
|
[environment variables]
|
||||||
|
# PATH = /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/sbin:/usr/sbin:/usr/local/bin:/usr/local/sbin
|
||||||
|
# PYTHONPATH =
|
||||||
|
# TZ = :/etc/localtime
|
||||||
|
|
||||||
|
[host labels]
|
||||||
|
# name = value
|
||||||
|
|
||||||
|
[cloud]
|
||||||
|
# conversation log = no
|
||||||
|
# scope = full
|
||||||
|
# query threads = 6
|
||||||
|
# proxy = env
|
||||||
|
|
||||||
|
[ml]
|
||||||
|
# enabled = auto
|
||||||
|
# maximum num samples to train = 21600
|
||||||
|
# minimum num samples to train = 900
|
||||||
|
# train every = 3h
|
||||||
|
# number of models per dimension = 18
|
||||||
|
# delete models older than = 7d
|
||||||
|
# num samples to diff = 1
|
||||||
|
# num samples to smooth = 3
|
||||||
|
# num samples to lag = 5
|
||||||
|
# random sampling ratio = 0.20000
|
||||||
|
# maximum number of k-means iterations = 1000
|
||||||
|
# dimension anomaly score threshold = 0.99000
|
||||||
|
# host anomaly rate threshold = 1.00000
|
||||||
|
# anomaly detection grouping method = average
|
||||||
|
# anomaly detection grouping duration = 5m
|
||||||
|
# num training threads = 1
|
||||||
|
# flush models batch size = 256
|
||||||
|
# dimension anomaly rate suppression window = 15m
|
||||||
|
# dimension anomaly rate suppression threshold = 450
|
||||||
|
# enable statistics charts = yes
|
||||||
|
# hosts to skip from training = !*
|
||||||
|
# charts to skip from training = netdata.*
|
||||||
|
# stream anomaly detection charts = yes
|
||||||
|
|
||||||
|
[health]
|
||||||
|
# silencers file = /var/lib/netdata/health.silencers.json
|
||||||
|
# enabled = yes
|
||||||
|
# enable stock health configuration = yes
|
||||||
|
# use summary for notifications = yes
|
||||||
|
# default repeat warning = off
|
||||||
|
# default repeat critical = off
|
||||||
|
# in memory max health log entries = 1000
|
||||||
|
# health log retention = 5d
|
||||||
|
# script to execute on alarm = /usr/libexec/netdata/plugins.d/alarm-notify.sh
|
||||||
|
# enabled alarms = *
|
||||||
|
# run at least every = 10s
|
||||||
|
# postpone alarms during hibernation for = 1m
|
||||||
|
|
||||||
|
[web]
|
||||||
|
#| >>> [web].default port <<<
|
||||||
|
#| migrated from: [global].default port
|
||||||
|
# default port = 19999
|
||||||
|
|
||||||
|
# ssl key = /etc/netdata/ssl/key.pem
|
||||||
|
# ssl certificate = /etc/netdata/ssl/cert.pem
|
||||||
|
# tls version = 1.3
|
||||||
|
# tls ciphers = none
|
||||||
|
# ses max tg_des_window = 15
|
||||||
|
# des max tg_des_window = 15
|
||||||
|
# mode = static-threaded
|
||||||
|
# listen backlog = 4096
|
||||||
|
# bind to = *
|
||||||
|
# bearer token protection = no
|
||||||
|
# disconnect idle clients after = 1m
|
||||||
|
# timeout for first request = 1m
|
||||||
|
# accept a streaming request every = off
|
||||||
|
# respect do not track policy = no
|
||||||
|
# x-frame-options response header =
|
||||||
|
# allow connections from = localhost *
|
||||||
|
# allow connections by dns = heuristic
|
||||||
|
# allow dashboard from = localhost *
|
||||||
|
# allow dashboard by dns = heuristic
|
||||||
|
# allow badges from = *
|
||||||
|
# allow badges by dns = heuristic
|
||||||
|
# allow streaming from = *
|
||||||
|
# allow streaming by dns = heuristic
|
||||||
|
# allow netdata.conf from = localhost fd* 10.* 192.168.* 172.16.* 172.17.* 172.18.* 172.19.* 172.20.* 172.21.* 172.22.* 172.23.* 172.24.* 172.25.* 172.26.* 172.27.* 172.28.* 172.29.* 172.30.* 172.31.* UNKNOWN
|
||||||
|
# allow netdata.conf by dns = no
|
||||||
|
# allow management from = localhost
|
||||||
|
# allow management by dns = heuristic
|
||||||
|
# enable gzip compression = yes
|
||||||
|
# gzip compression strategy = default
|
||||||
|
# gzip compression level = 3
|
||||||
|
# ssl skip certificate verification = no
|
||||||
|
# web server threads = 6
|
||||||
|
# web server max sockets = 262144
|
||||||
|
|
||||||
|
[registry]
|
||||||
|
# enabled = no
|
||||||
|
# registry db file = /var/lib/netdata/registry/registry.db
|
||||||
|
# registry log file = /var/lib/netdata/registry/registry-log.db
|
||||||
|
# registry save db every new entries = 1000000
|
||||||
|
# registry expire idle persons = 1y
|
||||||
|
# registry domain =
|
||||||
|
# registry to announce = https://registry.my-netdata.io
|
||||||
|
# registry hostname = 7171b7f9fc69
|
||||||
|
# verify browser cookies support = yes
|
||||||
|
# enable cookies SameSite and Secure = yes
|
||||||
|
# max URL length = 1024
|
||||||
|
# max URL name length = 50
|
||||||
|
# netdata management api key file = /var/lib/netdata/netdata.api.key
|
||||||
|
# allow from = *
|
||||||
|
# allow by dns = heuristic
|
||||||
|
|
||||||
|
[pulse]
|
||||||
|
# extended = no
|
||||||
|
# update every = 1s
|
||||||
|
|
||||||
|
[plugins]
|
||||||
|
# idlejitter = yes
|
||||||
|
# netdata pulse = yes
|
||||||
|
# profile = no
|
||||||
|
# tc = yes
|
||||||
|
# diskspace = yes
|
||||||
|
# proc = yes
|
||||||
|
# cgroups = yes
|
||||||
|
# timex = yes
|
||||||
|
# statsd = yes
|
||||||
|
# enable running new plugins = yes
|
||||||
|
# check for new plugins every = 1m
|
||||||
|
# slabinfo = no
|
||||||
|
# freeipmi = no
|
||||||
|
# python.d = yes
|
||||||
|
# go.d = yes
|
||||||
|
# apps = yes
|
||||||
|
# systemd-journal = yes
|
||||||
|
# network-viewer = yes
|
||||||
|
# charts.d = yes
|
||||||
|
# debugfs = yes
|
||||||
|
# perf = yes
|
||||||
|
# ioping = yes
|
||||||
|
|
||||||
|
[statsd]
|
||||||
|
# update every (flushInterval) = 1s
|
||||||
|
# udp messages to process at once = 10
|
||||||
|
# create private charts for metrics matching = *
|
||||||
|
# max private charts hard limit = 1000
|
||||||
|
# set charts as obsolete after = off
|
||||||
|
# decimal detail = 1000
|
||||||
|
# disconnect idle tcp clients after = 10m
|
||||||
|
# private charts hidden = no
|
||||||
|
# histograms and timers percentile (percentThreshold) = 95.00000
|
||||||
|
# dictionaries max unique dimensions = 200
|
||||||
|
# add dimension for number of events received = no
|
||||||
|
# gaps on gauges (deleteGauges) = no
|
||||||
|
# gaps on counters (deleteCounters) = no
|
||||||
|
# gaps on meters (deleteMeters) = no
|
||||||
|
# gaps on sets (deleteSets) = no
|
||||||
|
# gaps on histograms (deleteHistograms) = no
|
||||||
|
# gaps on timers (deleteTimers) = no
|
||||||
|
# gaps on dictionaries (deleteDictionaries) = no
|
||||||
|
# statsd server max TCP sockets = 262144
|
||||||
|
# listen backlog = 4096
|
||||||
|
# default port = 8125
|
||||||
|
# bind to = udp:localhost tcp:localhost
|
||||||
|
|
||||||
|
[plugin:idlejitter]
|
||||||
|
# loop time = 20ms
|
||||||
|
|
||||||
|
[plugin:timex]
|
||||||
|
# update every = 10s
|
||||||
|
# clock synchronization state = yes
|
||||||
|
# time offset = yes
|
||||||
|
|
||||||
|
[plugin:proc]
|
||||||
|
# /proc/net/dev = yes
|
||||||
|
# /proc/pagetypeinfo = no
|
||||||
|
# /proc/stat = yes
|
||||||
|
# /proc/uptime = yes
|
||||||
|
# /proc/loadavg = yes
|
||||||
|
# /proc/sys/fs/file-nr = yes
|
||||||
|
# /proc/sys/kernel/random/entropy_avail = yes
|
||||||
|
# /run/reboot_required = yes
|
||||||
|
# /proc/pressure = yes
|
||||||
|
# /proc/interrupts = yes
|
||||||
|
# /proc/softirqs = yes
|
||||||
|
# /proc/vmstat = yes
|
||||||
|
# /proc/meminfo = yes
|
||||||
|
# /sys/kernel/mm/ksm = yes
|
||||||
|
# /sys/block/zram = yes
|
||||||
|
# /sys/devices/system/edac/mc = yes
|
||||||
|
# /sys/devices/pci/aer = yes
|
||||||
|
# /sys/devices/system/node = yes
|
||||||
|
# /proc/net/wireless = yes
|
||||||
|
# /proc/net/sockstat = yes
|
||||||
|
# /proc/net/sockstat6 = yes
|
||||||
|
# /proc/net/netstat = yes
|
||||||
|
# /proc/net/sctp/snmp = yes
|
||||||
|
# /proc/net/softnet_stat = yes
|
||||||
|
# /proc/net/ip_vs/stats = yes
|
||||||
|
# /sys/class/infiniband = yes
|
||||||
|
# /proc/net/stat/conntrack = yes
|
||||||
|
# /proc/net/stat/synproxy = yes
|
||||||
|
# /proc/diskstats = yes
|
||||||
|
# /proc/mdstat = yes
|
||||||
|
# /proc/net/rpc/nfsd = yes
|
||||||
|
# /proc/net/rpc/nfs = yes
|
||||||
|
# /proc/spl/kstat/zfs/arcstats = yes
|
||||||
|
# /sys/fs/btrfs = yes
|
||||||
|
# ipc = yes
|
||||||
|
# /sys/class/power_supply = yes
|
||||||
|
# /sys/class/drm = yes
|
||||||
|
|
||||||
|
[plugin:cgroups]
|
||||||
|
# update every = 1s
|
||||||
|
# check for new cgroups every = 10s
|
||||||
|
# use unified cgroups = auto
|
||||||
|
# max cgroups to allow = 1000
|
||||||
|
# max cgroups depth to monitor = 0
|
||||||
|
# enable by default cgroups matching = !*/init.scope !/system.slice/run-*.scope *user.slice/docker-* !*user.slice* *.scope !/machine.slice/*/.control !/machine.slice/*/payload* !/machine.slice/*/supervisor /machine.slice/*.service */kubepods/pod*/* */kubepods/*/pod*/* */*-kubepods-pod*/* */*-kubepods-*-pod*/* !*kubepods* !*kubelet* !*/vcpu* !*/emulator !*.mount !*.partition !*.service !*.service/udev !*.socket !*.slice !*.swap !*.user !/ !/docker !*/libvirt !/lxc !/lxc/*/* !/lxc.monitor* !/lxc.pivot !/lxc.payload !*lxcfs.service/.control !/machine !/qemu !/system !/systemd !/user *
|
||||||
|
# enable by default cgroups names matching = *
|
||||||
|
# search for cgroups in subpaths matching = !*/init.scope !*-qemu !*.libvirt-qemu !/init.scope !/system !/systemd !/user !/lxc/*/* !/lxc.monitor !/lxc.payload/*/* !/lxc.payload.* *
|
||||||
|
# script to get cgroup names = /usr/libexec/netdata/plugins.d/cgroup-name.sh
|
||||||
|
# script to get cgroup network interfaces = /usr/libexec/netdata/plugins.d/cgroup-network
|
||||||
|
# run script to rename cgroups matching = !/ !*.mount !*.socket !*.partition /machine.slice/*.service !*.service !*.slice !*.swap !*.user !init.scope !*.scope/vcpu* !*.scope/emulator *.scope *docker* *lxc* *qemu* */kubepods/pod*/* */kubepods/*/pod*/* */*-kubepods-pod*/* */*-kubepods-*-pod*/* !*kubepods* !*kubelet* *.libvirt-qemu *
|
||||||
|
# cgroups to match as systemd services = !/system.slice/*/*.service /system.slice/*.service
|
||||||
|
|
||||||
|
[plugin:proc:diskspace]
|
||||||
|
# remove charts of unmounted disks = yes
|
||||||
|
# update every = 1s
|
||||||
|
# check for new mount points every = 15s
|
||||||
|
# exclude space metrics on paths = /dev /dev/shm /proc/* /sys/* /var/run/user/* /run/lock /run/user/* /snap/* /var/lib/docker/* /var/lib/containers/storage/* /run/credentials/* /run/containerd/* /rpool /rpool/*
|
||||||
|
# exclude space metrics on filesystems = *gvfs *gluster* *s3fs *ipfs *davfs2 *httpfs *sshfs *gdfs *moosefs fusectl autofs cgroup cgroup2 hugetlbfs devtmpfs fuse.lxcfs
|
||||||
|
# exclude inode metrics on filesystems = msdosfs msdos vfat overlayfs aufs* *unionfs
|
||||||
|
# space usage for all disks = auto
|
||||||
|
# inodes usage for all disks = auto
|
||||||
|
|
||||||
|
[plugin:tc]
|
||||||
|
# script to run to get tc values = /usr/libexec/netdata/plugins.d/tc-qos-helper.sh
|
||||||
|
|
||||||
|
[plugin:python.d]
|
||||||
|
# update every = 1s
|
||||||
|
# command options =
|
||||||
|
|
||||||
|
[plugin:go.d]
|
||||||
|
# update every = 1s
|
||||||
|
# command options =
|
||||||
|
|
||||||
|
[plugin:apps]
|
||||||
|
# update every = 1s
|
||||||
|
# command options =
|
||||||
|
|
||||||
|
[plugin:systemd-journal]
|
||||||
|
# update every = 1s
|
||||||
|
# command options =
|
||||||
|
|
||||||
|
[plugin:network-viewer]
|
||||||
|
# update every = 1s
|
||||||
|
# command options =
|
||||||
|
|
||||||
|
[plugin:charts.d]
|
||||||
|
# update every = 1s
|
||||||
|
# command options =
|
||||||
|
|
||||||
|
[plugin:debugfs]
|
||||||
|
# update every = 1s
|
||||||
|
# command options =
|
||||||
|
|
||||||
|
[plugin:perf]
|
||||||
|
# update every = 1s
|
||||||
|
# command options =
|
||||||
|
|
||||||
|
[plugin:ioping]
|
||||||
|
# update every = 1s
|
||||||
|
# command options =
|
||||||
|
|
||||||
|
[plugin:proc:/proc/net/dev]
|
||||||
|
# compressed packets for all interfaces = no
|
||||||
|
# disable by default interfaces matching = lo fireqos* *-ifb fwpr* fwbr* fwln* ifb4*
|
||||||
|
|
||||||
|
[plugin:proc:/proc/stat]
|
||||||
|
# cpu utilization = yes
|
||||||
|
# per cpu core utilization = no
|
||||||
|
# cpu interrupts = yes
|
||||||
|
# context switches = yes
|
||||||
|
# processes started = yes
|
||||||
|
# processes running = yes
|
||||||
|
# keep per core files open = yes
|
||||||
|
# keep cpuidle files open = yes
|
||||||
|
# core_throttle_count = auto
|
||||||
|
# package_throttle_count = no
|
||||||
|
# cpu frequency = yes
|
||||||
|
# cpu idle states = no
|
||||||
|
# core_throttle_count filename to monitor = /host/sys/devices/system/cpu/%s/thermal_throttle/core_throttle_count
|
||||||
|
# package_throttle_count filename to monitor = /host/sys/devices/system/cpu/%s/thermal_throttle/package_throttle_count
|
||||||
|
# scaling_cur_freq filename to monitor = /host/sys/devices/system/cpu/%s/cpufreq/scaling_cur_freq
|
||||||
|
# time_in_state filename to monitor = /host/sys/devices/system/cpu/%s/cpufreq/stats/time_in_state
|
||||||
|
# schedstat filename to monitor = /host/proc/schedstat
|
||||||
|
# cpuidle name filename to monitor = /host/sys/devices/system/cpu/cpu%zu/cpuidle/state%zu/name
|
||||||
|
# cpuidle time filename to monitor = /host/sys/devices/system/cpu/cpu%zu/cpuidle/state%zu/time
|
||||||
|
# filename to monitor = /host/proc/stat
|
||||||
|
|
||||||
|
[plugin:proc:/proc/uptime]
|
||||||
|
# filename to monitor = /host/proc/uptime
|
||||||
|
|
||||||
|
[plugin:proc:/proc/loadavg]
|
||||||
|
# filename to monitor = /host/proc/loadavg
|
||||||
|
# enable load average = yes
|
||||||
|
# enable total processes = yes
|
||||||
|
|
||||||
|
[plugin:proc:/proc/sys/fs/file-nr]
|
||||||
|
# filename to monitor = /host/proc/sys/fs/file-nr
|
||||||
|
|
||||||
|
[plugin:proc:/proc/sys/kernel/random/entropy_avail]
|
||||||
|
# filename to monitor = /host/proc/sys/kernel/random/entropy_avail
|
||||||
|
|
||||||
|
[plugin:proc:/proc/pressure]
|
||||||
|
# base path of pressure metrics = /proc/pressure
|
||||||
|
# enable cpu some pressure = yes
|
||||||
|
# enable cpu full pressure = no
|
||||||
|
# enable memory some pressure = yes
|
||||||
|
# enable memory full pressure = yes
|
||||||
|
# enable io some pressure = yes
|
||||||
|
# enable io full pressure = yes
|
||||||
|
# enable irq some pressure = no
|
||||||
|
# enable irq full pressure = yes
|
||||||
|
|
||||||
|
[plugin:proc:/proc/interrupts]
|
||||||
|
# interrupts per core = no
|
||||||
|
# filename to monitor = /host/proc/interrupts
|
||||||
|
|
||||||
|
[plugin:proc:/proc/softirqs]
|
||||||
|
# interrupts per core = no
|
||||||
|
# filename to monitor = /host/proc/softirqs
|
||||||
|
|
||||||
|
[plugin:proc:/proc/vmstat]
|
||||||
|
# filename to monitor = /host/proc/vmstat
|
||||||
|
# swap i/o = auto
|
||||||
|
# disk i/o = yes
|
||||||
|
# memory page faults = yes
|
||||||
|
# out of memory kills = yes
|
||||||
|
# system-wide numa metric summary = auto
|
||||||
|
# transparent huge pages = auto
|
||||||
|
# zswap i/o = auto
|
||||||
|
# memory ballooning = auto
|
||||||
|
# kernel same memory = auto
|
||||||
|
|
||||||
|
[plugin:proc:/sys/devices/system/node]
|
||||||
|
# directory to monitor = /host/sys/devices/system/node
|
||||||
|
# enable per-node numa metrics = auto
|
||||||
|
|
||||||
|
[plugin:proc:/proc/meminfo]
|
||||||
|
# system ram = yes
|
||||||
|
# system swap = auto
|
||||||
|
# hardware corrupted ECC = auto
|
||||||
|
# committed memory = yes
|
||||||
|
# writeback memory = yes
|
||||||
|
# kernel memory = yes
|
||||||
|
# slab memory = yes
|
||||||
|
# hugepages = auto
|
||||||
|
# transparent hugepages = auto
|
||||||
|
# memory reclaiming = yes
|
||||||
|
# high low memory = yes
|
||||||
|
# cma memory = auto
|
||||||
|
# direct maps = yes
|
||||||
|
# filename to monitor = /host/proc/meminfo
|
||||||
|
|
||||||
|
[plugin:proc:/sys/kernel/mm/ksm]
|
||||||
|
# /sys/kernel/mm/ksm/pages_shared = /host/sys/kernel/mm/ksm/pages_shared
|
||||||
|
# /sys/kernel/mm/ksm/pages_sharing = /host/sys/kernel/mm/ksm/pages_sharing
|
||||||
|
# /sys/kernel/mm/ksm/pages_unshared = /host/sys/kernel/mm/ksm/pages_unshared
|
||||||
|
# /sys/kernel/mm/ksm/pages_volatile = /host/sys/kernel/mm/ksm/pages_volatile
|
||||||
|
|
||||||
|
[plugin:proc:/sys/devices/system/edac/mc]
|
||||||
|
# directory to monitor = /host/sys/devices/system/edac/mc
|
||||||
|
|
||||||
|
[plugin:proc:/sys/class/pci/aer]
|
||||||
|
# enable root ports = no
|
||||||
|
# enable pci slots = no
|
||||||
|
|
||||||
|
[plugin:proc:/proc/net/wireless]
|
||||||
|
# filename to monitor = /host/proc/net/wireless
|
||||||
|
# status for all interfaces = auto
|
||||||
|
# quality for all interfaces = auto
|
||||||
|
# discarded packets for all interfaces = auto
|
||||||
|
# missed beacon for all interface = auto
|
||||||
|
|
||||||
|
[plugin:proc:/proc/net/sockstat]
|
||||||
|
# ipv4 sockets = auto
|
||||||
|
# ipv4 TCP sockets = auto
|
||||||
|
# ipv4 TCP memory = auto
|
||||||
|
# ipv4 UDP sockets = auto
|
||||||
|
# ipv4 UDP memory = auto
|
||||||
|
# ipv4 UDPLITE sockets = auto
|
||||||
|
# ipv4 RAW sockets = auto
|
||||||
|
# ipv4 FRAG sockets = auto
|
||||||
|
# ipv4 FRAG memory = auto
|
||||||
|
# update constants every = 1m
|
||||||
|
# filename to monitor = /host/proc/net/sockstat
|
||||||
|
|
||||||
|
[plugin:proc:/proc/net/sockstat6]
|
||||||
|
# ipv6 TCP sockets = auto
|
||||||
|
# ipv6 UDP sockets = auto
|
||||||
|
# ipv6 UDPLITE sockets = auto
|
||||||
|
# ipv6 RAW sockets = auto
|
||||||
|
# ipv6 FRAG sockets = auto
|
||||||
|
# filename to monitor = /host/proc/net/sockstat6
|
||||||
|
|
||||||
|
[plugin:proc:/proc/net/netstat]
|
||||||
|
# bandwidth = auto
|
||||||
|
# input errors = auto
|
||||||
|
# multicast bandwidth = auto
|
||||||
|
# broadcast bandwidth = auto
|
||||||
|
# multicast packets = auto
|
||||||
|
# broadcast packets = auto
|
||||||
|
# ECN packets = auto
|
||||||
|
# TCP reorders = auto
|
||||||
|
# TCP SYN cookies = auto
|
||||||
|
# TCP out-of-order queue = auto
|
||||||
|
# TCP connection aborts = auto
|
||||||
|
# TCP memory pressures = auto
|
||||||
|
# TCP SYN queue = auto
|
||||||
|
# TCP accept queue = auto
|
||||||
|
# filename to monitor = /host/proc/net/netstat
|
||||||
|
|
||||||
|
[plugin:proc:/proc/net/snmp]
|
||||||
|
# ipv4 packets = auto
|
||||||
|
# ipv4 fragments sent = auto
|
||||||
|
# ipv4 fragments assembly = auto
|
||||||
|
# ipv4 errors = auto
|
||||||
|
# ipv4 TCP connections = auto
|
||||||
|
# ipv4 TCP packets = auto
|
||||||
|
# ipv4 TCP errors = auto
|
||||||
|
# ipv4 TCP opens = auto
|
||||||
|
# ipv4 TCP handshake issues = auto
|
||||||
|
# ipv4 UDP packets = auto
|
||||||
|
# ipv4 UDP errors = auto
|
||||||
|
# ipv4 ICMP packets = auto
|
||||||
|
# ipv4 ICMP messages = auto
|
||||||
|
# ipv4 UDPLite packets = auto
|
||||||
|
# filename to monitor = /host/proc/net/snmp
|
||||||
|
|
||||||
|
[plugin:proc:/proc/net/snmp6]
|
||||||
|
# ipv6 packets = auto
|
||||||
|
# ipv6 fragments sent = auto
|
||||||
|
# ipv6 fragments assembly = auto
|
||||||
|
# ipv6 errors = auto
|
||||||
|
# ipv6 UDP packets = auto
|
||||||
|
# ipv6 UDP errors = auto
|
||||||
|
# ipv6 UDPlite packets = auto
|
||||||
|
# ipv6 UDPlite errors = auto
|
||||||
|
# bandwidth = auto
|
||||||
|
# multicast bandwidth = auto
|
||||||
|
# broadcast bandwidth = auto
|
||||||
|
# multicast packets = auto
|
||||||
|
# icmp = auto
|
||||||
|
# icmp redirects = auto
|
||||||
|
# icmp errors = auto
|
||||||
|
# icmp echos = auto
|
||||||
|
# icmp group membership = auto
|
||||||
|
# icmp router = auto
|
||||||
|
# icmp neighbor = auto
|
||||||
|
# icmp mldv2 = auto
|
||||||
|
# icmp types = auto
|
||||||
|
# ect = auto
|
||||||
|
# filename to monitor = /host/proc/net/snmp6
|
||||||
|
|
||||||
|
[plugin:proc:/proc/net/sctp/snmp]
|
||||||
|
# established associations = auto
|
||||||
|
# association transitions = auto
|
||||||
|
# fragmentation = auto
|
||||||
|
# packets = auto
|
||||||
|
# packet errors = auto
|
||||||
|
# chunk types = auto
|
||||||
|
# filename to monitor = /host/proc/net/sctp/snmp
|
||||||
|
|
||||||
|
[plugin:proc:/proc/net/softnet_stat]
|
||||||
|
# softnet_stat per core = no
|
||||||
|
# filename to monitor = /host/proc/net/softnet_stat
|
||||||
|
|
||||||
|
[plugin:proc:/proc/net/ip_vs_stats]
|
||||||
|
# IPVS bandwidth = yes
|
||||||
|
# IPVS connections = yes
|
||||||
|
# IPVS packets = yes
|
||||||
|
# filename to monitor = /host/proc/net/ip_vs_stats
|
||||||
|
|
||||||
|
[plugin:proc:/sys/class/infiniband]
|
||||||
|
# dirname to monitor = /host/sys/class/infiniband
|
||||||
|
# bandwidth counters = yes
|
||||||
|
# packets counters = yes
|
||||||
|
# errors counters = yes
|
||||||
|
# hardware packets counters = auto
|
||||||
|
# hardware errors counters = auto
|
||||||
|
# monitor only active ports = auto
|
||||||
|
# disable by default interfaces matching =
|
||||||
|
# refresh ports state every = 30s
|
||||||
|
|
||||||
|
[plugin:proc:/proc/net/stat/nf_conntrack]
|
||||||
|
# filename to monitor = /host/proc/net/stat/nf_conntrack
|
||||||
|
# netfilter new connections = no
|
||||||
|
# netfilter connection changes = no
|
||||||
|
# netfilter connection expectations = no
|
||||||
|
# netfilter connection searches = no
|
||||||
|
# netfilter errors = no
|
||||||
|
# netfilter connections = yes
|
||||||
|
|
||||||
|
[plugin:proc:/proc/sys/net/netfilter/nf_conntrack_max]
|
||||||
|
# filename to monitor = /host/proc/sys/net/netfilter/nf_conntrack_max
|
||||||
|
# read every seconds = 10
|
||||||
|
|
||||||
|
[plugin:proc:/proc/sys/net/netfilter/nf_conntrack_count]
|
||||||
|
# filename to monitor = /host/proc/sys/net/netfilter/nf_conntrack_count
|
||||||
|
|
||||||
|
[plugin:proc:/proc/net/stat/synproxy]
|
||||||
|
# SYNPROXY cookies = auto
|
||||||
|
# SYNPROXY SYN received = auto
|
||||||
|
# SYNPROXY connections reopened = auto
|
||||||
|
# filename to monitor = /host/proc/net/stat/synproxy
|
||||||
|
|
||||||
|
[plugin:proc:/proc/diskstats]
|
||||||
|
# enable new disks detected at runtime = yes
|
||||||
|
# performance metrics for physical disks = auto
|
||||||
|
# performance metrics for virtual disks = auto
|
||||||
|
# performance metrics for partitions = no
|
||||||
|
# bandwidth for all disks = auto
|
||||||
|
# operations for all disks = auto
|
||||||
|
# merged operations for all disks = auto
|
||||||
|
# i/o time for all disks = auto
|
||||||
|
# queued operations for all disks = auto
|
||||||
|
# utilization percentage for all disks = auto
|
||||||
|
# extended operations for all disks = auto
|
||||||
|
# backlog for all disks = auto
|
||||||
|
# bcache for all disks = auto
|
||||||
|
# bcache priority stats update every = off
|
||||||
|
# remove charts of removed disks = yes
|
||||||
|
# path to get block device = /host/sys/block/%s
|
||||||
|
# path to get block device bcache = /host/sys/block/%s/bcache
|
||||||
|
# path to get virtual block device = /host/sys/devices/virtual/block/%s
|
||||||
|
# path to get block device infos = /host/sys/dev/block/%lu:%lu/%s
|
||||||
|
# path to device mapper = /host/dev/mapper
|
||||||
|
# path to /dev/disk = /host/dev/disk
|
||||||
|
# path to /sys/block = /host/sys/block
|
||||||
|
# path to /dev/disk/by-label = /host/dev/disk/by-label
|
||||||
|
# path to /dev/disk/by-id = /host/dev/disk/by-id
|
||||||
|
# path to /dev/vx/dsk = /host/dev/vx/dsk
|
||||||
|
# name disks by id = no
|
||||||
|
# preferred disk ids = *
|
||||||
|
# exclude disks = loop* ram*
|
||||||
|
# filename to monitor = /host/proc/diskstats
|
||||||
|
# performance metrics for disks with major 252 = yes
|
||||||
|
|
||||||
|
[plugin:proc:/proc/mdstat]
|
||||||
|
# faulty devices = yes
|
||||||
|
# nonredundant arrays availability = yes
|
||||||
|
# mismatch count = auto
|
||||||
|
# disk stats = yes
|
||||||
|
# operation status = yes
|
||||||
|
# make charts obsolete = yes
|
||||||
|
# filename to monitor = /host/proc/mdstat
|
||||||
|
# mismatch_cnt filename to monitor = /host/sys/block/%s/md/mismatch_cnt
|
||||||
|
|
||||||
|
[plugin:proc:/proc/net/rpc/nfsd]
|
||||||
|
# filename to monitor = /host/proc/net/rpc/nfsd
|
||||||
|
|
||||||
|
[plugin:proc:/proc/net/rpc/nfs]
|
||||||
|
# filename to monitor = /host/proc/net/rpc/nfs
|
||||||
|
|
||||||
|
[plugin:proc:/proc/spl/kstat/zfs/arcstats]
|
||||||
|
# filename to monitor = /host/proc/spl/kstat/zfs/arcstats
|
||||||
|
|
||||||
|
[plugin:proc:/sys/fs/btrfs]
|
||||||
|
# path to monitor = /host/sys/fs/btrfs
|
||||||
|
# check for btrfs changes every = 1m
|
||||||
|
# physical disks allocation = auto
|
||||||
|
# data allocation = auto
|
||||||
|
# metadata allocation = auto
|
||||||
|
# system allocation = auto
|
||||||
|
# commit stats = auto
|
||||||
|
# error stats = auto
|
||||||
|
|
||||||
|
[plugin:proc:ipc]
|
||||||
|
# message queues = yes
|
||||||
|
# semaphore totals = yes
|
||||||
|
# shared memory totals = yes
|
||||||
|
# msg filename to monitor = /host/proc/sysvipc/msg
|
||||||
|
# shm filename to monitor = /host/proc/sysvipc/shm
|
||||||
|
# max dimensions in memory allowed = 50
|
||||||
|
|
||||||
|
[plugin:proc:/sys/class/power_supply]
|
||||||
|
# battery capacity = yes
|
||||||
|
# battery power = yes
|
||||||
|
# battery charge = no
|
||||||
|
# battery energy = no
|
||||||
|
# power supply voltage = no
|
||||||
|
# keep files open = auto
|
||||||
|
# directory to monitor = /host/sys/class/power_supply
|
||||||
|
|
||||||
|
[plugin:proc:/sys/class/drm]
|
||||||
|
# directory to monitor = /host/sys/class/drm
|
25
files/outline/backup.sh.j2
Normal file
25
files/outline/backup.sh.j2
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
set -eu
|
||||||
|
set -o pipefail
|
||||||
|
|
||||||
|
TIMESTAMP=$(date +%Y%m%d_%H%M%S)
|
||||||
|
BACKUP_FILE="outline_postgres_${TIMESTAMP}.sql.gz"
|
||||||
|
|
||||||
|
echo "Outline: backing up PostgreSQL database"
|
||||||
|
|
||||||
|
docker compose --file "{{ base_dir }}/docker-compose.yml" exec \
|
||||||
|
outline_postgres \
|
||||||
|
pg_dump \
|
||||||
|
-U "{{ outline_postgres_user }}" \
|
||||||
|
"{{ outline_postgres_database }}" \
|
||||||
|
| gzip > "{{ postgres_backups_dir }}/${BACKUP_FILE}"
|
||||||
|
|
||||||
|
echo "Outline: PostgreSQL backup saved to {{ postgres_backups_dir }}/${BACKUP_FILE}"
|
||||||
|
|
||||||
|
echo "Outline: removing old backups"
|
||||||
|
|
||||||
|
# Keep only the 3 most recent backups
|
||||||
|
keep-files.py "{{ postgres_backups_dir }}" --keep 3
|
||||||
|
|
||||||
|
echo "Outline: backup completed successfully."
|
@ -3,17 +3,21 @@ services:
|
|||||||
# See sample https://github.com/outline/outline/blob/main/.env.sample
|
# See sample https://github.com/outline/outline/blob/main/.env.sample
|
||||||
|
|
||||||
outline_app:
|
outline_app:
|
||||||
image: outlinewiki/outline:0.81.1
|
image: outlinewiki/outline:0.84.0
|
||||||
container_name: outline_app
|
container_name: outline_app
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
ports:
|
|
||||||
- "127.0.0.1:{{ outline_port }}:3000"
|
|
||||||
depends_on:
|
depends_on:
|
||||||
- outline_postgres
|
- outline_postgres
|
||||||
- outline_redis
|
- outline_redis
|
||||||
|
ports:
|
||||||
|
- "127.0.0.1:{{ outline_port }}:3000"
|
||||||
|
networks:
|
||||||
|
- "outline_network"
|
||||||
|
- "{{ web_proxy_network }}"
|
||||||
environment:
|
environment:
|
||||||
NODE_ENV: 'production'
|
NODE_ENV: 'production'
|
||||||
URL: 'https://outline.vakhrushev.me'
|
URL: 'https://outline.vakhrushev.me'
|
||||||
|
FORCE_HTTPS: 'true'
|
||||||
SECRET_KEY: '{{ outline_secret_key }}'
|
SECRET_KEY: '{{ outline_secret_key }}'
|
||||||
UTILS_SECRET: '{{ outline_utils_secret }}'
|
UTILS_SECRET: '{{ outline_utils_secret }}'
|
||||||
DATABASE_URL: 'postgres://{{ outline_postgres_user }}:{{ outline_postgres_password }}@outline_postgres:5432/{{ outline_postgres_database }}'
|
DATABASE_URL: 'postgres://{{ outline_postgres_user }}:{{ outline_postgres_password }}@outline_postgres:5432/{{ outline_postgres_database }}'
|
||||||
@ -31,30 +35,47 @@ services:
|
|||||||
AWS_S3_FORCE_PATH_STYLE: 'true'
|
AWS_S3_FORCE_PATH_STYLE: 'true'
|
||||||
AWS_S3_ACL: 'private'
|
AWS_S3_ACL: 'private'
|
||||||
|
|
||||||
OIDC_CLIENT_ID: '{{ outline_oidc_client_id }}'
|
OIDC_CLIENT_ID: '{{ outline_oidc_client_id | replace("$", "$$") }}'
|
||||||
OIDC_CLIENT_SECRET: '{{ outline_oidc_client_secret }}'
|
OIDC_CLIENT_SECRET: '{{ outline_oidc_client_secret | replace("$", "$$") }}'
|
||||||
OIDC_AUTH_URI: 'https://kk.vakhrushev.me/realms/outline/protocol/openid-connect/auth'
|
OIDC_AUTH_URI: 'https://auth.vakhrushev.me/api/oidc/authorization'
|
||||||
OIDC_TOKEN_URI: 'https://kk.vakhrushev.me/realms/outline/protocol/openid-connect/token'
|
OIDC_TOKEN_URI: 'https://auth.vakhrushev.me/api/oidc/token'
|
||||||
OIDC_USERINFO_URI: 'https://kk.vakhrushev.me/realms/outline/protocol/openid-connect/userinfo'
|
OIDC_USERINFO_URI: 'https://auth.vakhrushev.me/api/oidc/userinfo'
|
||||||
OIDC_LOGOUT_URI: 'https://kk.vakhrushev.me/realms/outline/protocol/openid-connect/logout'
|
OIDC_LOGOUT_URI: 'https://auth.vakhrushev.me/logout'
|
||||||
OIDC_USERNAME_CLAIM: 'email'
|
OIDC_USERNAME_CLAIM: 'email'
|
||||||
OIDC_DISPLAY_NAME: 'KK'
|
OIDC_SCOPES: 'openid profile email'
|
||||||
|
OIDC_DISPLAY_NAME: 'Authelia'
|
||||||
|
|
||||||
|
SMTP_HOST: '{{ postbox_host }}'
|
||||||
|
SMTP_PORT: '{{ postbox_port }}'
|
||||||
|
SMTP_USERNAME: '{{ postbox_user }}'
|
||||||
|
SMTP_PASSWORD: '{{ postbox_pass }}'
|
||||||
|
SMTP_FROM_EMAIL: 'outline@vakhrushev.me'
|
||||||
|
SMTP_TLS_CIPHERS: 'TLSv1.2'
|
||||||
|
SMTP_SECURE: 'false'
|
||||||
|
|
||||||
outline_redis:
|
outline_redis:
|
||||||
image: redis:7.2-bookworm
|
image: valkey/valkey:8.1.1-alpine
|
||||||
container_name: outline_redis
|
container_name: outline_redis
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
|
networks:
|
||||||
|
- "outline_network"
|
||||||
|
|
||||||
|
|
||||||
outline_postgres:
|
outline_postgres:
|
||||||
image: postgres:16.3-bookworm
|
image: postgres:16.3-bookworm
|
||||||
container_name: outline_postgres
|
container_name: outline_postgres
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
volumes:
|
volumes:
|
||||||
- ./data/postgres:/var/lib/postgresql/data
|
- {{ postgres_data_dir }}:/var/lib/postgresql/data
|
||||||
|
networks:
|
||||||
|
- "outline_network"
|
||||||
environment:
|
environment:
|
||||||
POSTGRES_USER: '{{ outline_postgres_user }}'
|
POSTGRES_USER: '{{ outline_postgres_user }}'
|
||||||
POSTGRES_PASSWORD: '{{ outline_postgres_password }}'
|
POSTGRES_PASSWORD: '{{ outline_postgres_password }}'
|
||||||
POSTGRES_DB: '{{ outline_postgres_database }}'
|
POSTGRES_DB: '{{ outline_postgres_database }}'
|
||||||
|
|
||||||
volumes:
|
networks:
|
||||||
database-data:
|
outline_network:
|
||||||
|
driver: bridge
|
||||||
|
{{ web_proxy_network }}:
|
||||||
|
external: true
|
||||||
|
@ -1,26 +0,0 @@
|
|||||||
$ANSIBLE_VAULT;1.1;AES256
|
|
||||||
66626231663733396232343163306138366434663364373937396137313134373033626539356166
|
|
||||||
3038316664383731623635336233393566636234636532630a393234336561613133373662383161
|
|
||||||
33653330663364363832346331653037663363643238326334326431336331373936666162363561
|
|
||||||
3064656630666431330a626430353063313866663730663236343437356661333164653636376538
|
|
||||||
62303164393766363933336163386663333030336132623661346565333861313537333566346563
|
|
||||||
32666436383335353866396539663936376134653762613137343035376639376135616334326161
|
|
||||||
62343366313032306664303030323433666230333665386630383635633863303366313639616462
|
|
||||||
38643466356666653337383833366565633932613539666563653634643063663166623337303865
|
|
||||||
64303365373932346233653237626363363964366431663966393937343966633735356563373735
|
|
||||||
66366464346436303036383161316466323639396162346537653134626663303662326462656563
|
|
||||||
63343065323636643266396532333331333137303131373633653233333837656665346635373564
|
|
||||||
62613733613634356335636663336634323463376266373665306232626330363132313362373032
|
|
||||||
30613366626563383236636262656135613431343639633339336135353362373665326264633438
|
|
||||||
65306539663166623533336531356639306235346566313764343835643437663963613639326430
|
|
||||||
36303031346339366561366166386532373838623635663837663466643032653930613635666237
|
|
||||||
38313235343662623733613637616164366134613635343135646439623464623233303330333361
|
|
||||||
62623166376337343838636564383633646432653436646236363262316438613333616236656532
|
|
||||||
37336539343130343133626262616634303561326631363564353064336130613666353531646237
|
|
||||||
66373036363764653435326638313036653135396362666439623431313930633539613965333263
|
|
||||||
39383937616165333962366134343936323930386233356662303864643236396562313339313739
|
|
||||||
64303934336164333563623263323236663531613265383833336239306435333735396666633666
|
|
||||||
30663566653361343238306133613839333962373838623633363138353331616264363064316433
|
|
||||||
36663233643134353333623264643238396438366633376530336134313365323832346663316535
|
|
||||||
66653436323338636565303133316637353338346366633564306230386632373235653836626338
|
|
||||||
3935
|
|
12
files/rssbridge/docker-compose.yml.j2
Normal file
12
files/rssbridge/docker-compose.yml.j2
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
services:
|
||||||
|
|
||||||
|
rssbridge_app:
|
||||||
|
image: rssbridge/rss-bridge:2025-06-03
|
||||||
|
container_name: rssbridge_app
|
||||||
|
restart: unless-stopped
|
||||||
|
networks:
|
||||||
|
- "{{ web_proxy_network }}"
|
||||||
|
|
||||||
|
networks:
|
||||||
|
{{ web_proxy_network }}:
|
||||||
|
external: true
|
10
files/wakapi/backup.sh.j2
Normal file
10
files/wakapi/backup.sh.j2
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
set -eu
|
||||||
|
set -o pipefail
|
||||||
|
|
||||||
|
echo "{{ app_name }}: backup data with gobackups"
|
||||||
|
|
||||||
|
(cd "{{ base_dir }}" && gobackup perform --config "{{ gobackup_config }}")
|
||||||
|
|
||||||
|
echo "{{ app_name }}: done."
|
32
files/wakapi/docker-compose.yml.j2
Normal file
32
files/wakapi/docker-compose.yml.j2
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
# See versions: https://github.com/gramps-project/gramps-web/pkgs/container/grampsweb
|
||||||
|
|
||||||
|
services:
|
||||||
|
|
||||||
|
wakapi_app:
|
||||||
|
image: ghcr.io/muety/wakapi:2.14.0
|
||||||
|
container_name: wakapi_app
|
||||||
|
restart: unless-stopped
|
||||||
|
user: '{{ user_create_result.uid }}:{{ user_create_result.group }}'
|
||||||
|
networks:
|
||||||
|
- "{{ web_proxy_network }}"
|
||||||
|
volumes:
|
||||||
|
- "{{ data_dir }}:/data"
|
||||||
|
environment:
|
||||||
|
WAKAPI_PUBLIC_URL: "https://wakapi.vakhrushev.me"
|
||||||
|
WAKAPI_PASSWORD_SALT: "{{ wakapi_password_salt }}"
|
||||||
|
WAKAPI_ALLOW_SIGNUP: "false"
|
||||||
|
WAKAPI_DISABLE_FRONTPAGE: "true"
|
||||||
|
WAKAPI_COOKIE_MAX_AGE: 31536000
|
||||||
|
# Mail
|
||||||
|
WAKAPI_MAIL_SENDER: "Wakapi <wakapi@vakhrushev.me>"
|
||||||
|
WAKAPI_MAIL_PROVIDER: "smtp"
|
||||||
|
WAKAPI_MAIL_SMTP_HOST: "{{ postbox_host }}"
|
||||||
|
WAKAPI_MAIL_SMTP_PORT: "{{ postbox_port }}"
|
||||||
|
WAKAPI_MAIL_SMTP_USER: "{{ postbox_user }}"
|
||||||
|
WAKAPI_MAIL_SMTP_PASS: "{{ postbox_pass }}"
|
||||||
|
WAKAPI_MAIL_SMTP_TLS: "false"
|
||||||
|
|
||||||
|
|
||||||
|
networks:
|
||||||
|
{{ web_proxy_network }}:
|
||||||
|
external: true
|
16
files/wakapi/gobackup.yml.j2
Normal file
16
files/wakapi/gobackup.yml.j2
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
# https://gobackup.github.io/configuration
|
||||||
|
|
||||||
|
models:
|
||||||
|
|
||||||
|
gramps:
|
||||||
|
compress_with:
|
||||||
|
type: 'tgz'
|
||||||
|
storages:
|
||||||
|
local:
|
||||||
|
type: 'local'
|
||||||
|
path: '{{ backups_dir }}'
|
||||||
|
keep: 3
|
||||||
|
databases:
|
||||||
|
wakapi:
|
||||||
|
type: sqlite
|
||||||
|
path: "{{ (data_dir, 'wakapi.db') | path_join }}"
|
@ -1 +0,0 @@
|
|||||||
192.168.50.10
|
|
@ -1,64 +0,0 @@
|
|||||||
---
|
|
||||||
- name: "Deploy homepage application"
|
|
||||||
hosts: all
|
|
||||||
|
|
||||||
vars_files:
|
|
||||||
- vars/ports.yml
|
|
||||||
- vars/vars.yml
|
|
||||||
|
|
||||||
vars:
|
|
||||||
app_name: "homepage"
|
|
||||||
base_dir: "/home/major/applications/{{ app_name }}/"
|
|
||||||
docker_registry_prefix: "cr.yandex/crplfk0168i4o8kd7ade"
|
|
||||||
homepage_web_image: "{{ homepage_web_image | default(omit) }}"
|
|
||||||
|
|
||||||
tasks:
|
|
||||||
- name: "Check is web service imape passed"
|
|
||||||
ansible.builtin.assert:
|
|
||||||
that:
|
|
||||||
- "homepage_web_image is defined"
|
|
||||||
fail_msg: 'You must pass variable "homepage_web_image"'
|
|
||||||
|
|
||||||
- name: "Create full image name with container registry"
|
|
||||||
ansible.builtin.set_fact:
|
|
||||||
registry_homepage_web_image: "{{ (docker_registry_prefix, homepage_web_image) | path_join }}"
|
|
||||||
|
|
||||||
- name: "Push web service image to remote registry"
|
|
||||||
community.docker.docker_image:
|
|
||||||
state: present
|
|
||||||
source: local
|
|
||||||
name: "{{ homepage_web_image }}"
|
|
||||||
repository: "{{ registry_homepage_web_image }}"
|
|
||||||
push: true
|
|
||||||
delegate_to: 127.0.0.1
|
|
||||||
|
|
||||||
- name: "Create application directories"
|
|
||||||
ansible.builtin.file:
|
|
||||||
path: "{{ item }}"
|
|
||||||
state: "directory"
|
|
||||||
mode: "0755"
|
|
||||||
loop:
|
|
||||||
- "{{ base_dir }}"
|
|
||||||
|
|
||||||
- name: "Copy application files"
|
|
||||||
ansible.builtin.copy:
|
|
||||||
src: "{{ item }}"
|
|
||||||
dest: "{{ base_dir }}"
|
|
||||||
mode: "0644"
|
|
||||||
loop:
|
|
||||||
- "./files/{{ app_name }}/docker-compose.yml"
|
|
||||||
|
|
||||||
- name: "Set up environment variables for application"
|
|
||||||
ansible.builtin.template:
|
|
||||||
src: "env.j2"
|
|
||||||
dest: '{{ (base_dir, ".env") | path_join }}'
|
|
||||||
mode: "0644"
|
|
||||||
vars:
|
|
||||||
env_dict:
|
|
||||||
WEB_SERVICE_IMAGE: "{{ registry_homepage_web_image }}"
|
|
||||||
WEB_SERVICE_PORT: "{{ homepage_port }}"
|
|
||||||
|
|
||||||
- name: "Run application with docker compose"
|
|
||||||
community.docker.docker_compose_v2:
|
|
||||||
project_src: "{{ base_dir }}"
|
|
||||||
state: "present"
|
|
68
playbook-authelia.yml
Normal file
68
playbook-authelia.yml
Normal file
@ -0,0 +1,68 @@
|
|||||||
|
---
|
||||||
|
- name: "Configure authelia application"
|
||||||
|
hosts: all
|
||||||
|
|
||||||
|
vars_files:
|
||||||
|
- vars/ports.yml
|
||||||
|
- vars/secrets.yml
|
||||||
|
|
||||||
|
vars:
|
||||||
|
app_name: "authelia"
|
||||||
|
app_user: "{{ app_name }}"
|
||||||
|
base_dir: "/home/{{ app_user }}"
|
||||||
|
config_dir: "{{ (base_dir, 'config') | path_join }}"
|
||||||
|
|
||||||
|
tasks:
|
||||||
|
- name: "Create user and environment"
|
||||||
|
ansible.builtin.import_role:
|
||||||
|
name: owner
|
||||||
|
vars:
|
||||||
|
owner_name: "{{ app_user }}"
|
||||||
|
owner_extra_groups: ["docker"]
|
||||||
|
|
||||||
|
- name: "Create internal application directories"
|
||||||
|
ansible.builtin.file:
|
||||||
|
path: "{{ item }}"
|
||||||
|
state: "directory"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0700"
|
||||||
|
loop:
|
||||||
|
- "{{ config_dir }}"
|
||||||
|
|
||||||
|
- name: "Copy configuration files"
|
||||||
|
ansible.builtin.copy:
|
||||||
|
src: "files/{{ app_name }}/{{ item }}"
|
||||||
|
dest: "{{ (config_dir, item) | path_join }}"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0600"
|
||||||
|
loop:
|
||||||
|
- "users.yml"
|
||||||
|
|
||||||
|
- name: "Copy configuration files (templates)"
|
||||||
|
ansible.builtin.template:
|
||||||
|
src: "files/{{ app_name }}/configuration.yml.j2"
|
||||||
|
dest: "{{ (config_dir, 'configuration.yml') | path_join }}"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0600"
|
||||||
|
|
||||||
|
- name: "Copy docker compose file"
|
||||||
|
ansible.builtin.template:
|
||||||
|
src: "./files/{{ app_name }}/docker-compose.yml.j2"
|
||||||
|
dest: "{{ base_dir }}/docker-compose.yml"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0640"
|
||||||
|
|
||||||
|
- name: "Run application with docker compose"
|
||||||
|
community.docker.docker_compose_v2:
|
||||||
|
project_src: "{{ base_dir }}"
|
||||||
|
state: "present"
|
||||||
|
remove_orphans: true
|
||||||
|
|
||||||
|
- name: "Restart application with docker compose"
|
||||||
|
community.docker.docker_compose_v2:
|
||||||
|
project_src: "{{ base_dir }}"
|
||||||
|
state: "restarted"
|
@ -3,36 +3,26 @@
|
|||||||
hosts: all
|
hosts: all
|
||||||
|
|
||||||
vars_files:
|
vars_files:
|
||||||
- vars/vars.yml
|
|
||||||
- vars/secrets.yml
|
- vars/secrets.yml
|
||||||
|
- vars/secrets.yml
|
||||||
|
|
||||||
|
vars:
|
||||||
|
restic_shell_script: "{{ (bin_prefix, 'restic-shell.sh') | path_join }}"
|
||||||
|
backup_all_script: "{{ (bin_prefix, 'backup-all.sh') | path_join }}"
|
||||||
|
|
||||||
tasks:
|
tasks:
|
||||||
- name: "Copy restic shell script"
|
- name: "Copy restic shell script"
|
||||||
ansible.builtin.template:
|
ansible.builtin.template:
|
||||||
src: "files/backups/restic-shell.sh.j2"
|
src: "files/backups/restic-shell.sh.j2"
|
||||||
dest: "{{ bin_prefix }}/restic-shell.sh"
|
dest: "{{ restic_shell_script }}"
|
||||||
owner: root
|
owner: root
|
||||||
group: root
|
group: root
|
||||||
mode: "0700"
|
mode: "0700"
|
||||||
|
|
||||||
- name: "Copy restic backup script"
|
- name: "Copy backup all script"
|
||||||
ansible.builtin.template:
|
ansible.builtin.template:
|
||||||
src: "files/backups/restic-backup.sh.j2"
|
src: "files/backups/backup-all.sh.j2"
|
||||||
dest: "{{ bin_prefix }}/restic-backup.sh"
|
dest: "{{ backup_all_script }}"
|
||||||
owner: root
|
|
||||||
group: root
|
|
||||||
mode: "0700"
|
|
||||||
|
|
||||||
- name: "Create gobackup config directory"
|
|
||||||
ansible.builtin.file:
|
|
||||||
path: "{{ backup_gobackup_config | dirname }}"
|
|
||||||
state: directory
|
|
||||||
mode: "0755"
|
|
||||||
|
|
||||||
- name: "Copy gobackup config files"
|
|
||||||
ansible.builtin.template:
|
|
||||||
src: "files/backups/gobackup.yml.j2"
|
|
||||||
dest: "{{ backup_gobackup_config }}"
|
|
||||||
owner: root
|
owner: root
|
||||||
group: root
|
group: root
|
||||||
mode: "0700"
|
mode: "0700"
|
||||||
@ -58,6 +48,6 @@
|
|||||||
name: "restic backup"
|
name: "restic backup"
|
||||||
minute: "0"
|
minute: "0"
|
||||||
hour: "1"
|
hour: "1"
|
||||||
job: "/usr/local/bin/restic-backup.sh 2>&1 | logger -t backup"
|
job: "{{ backup_all_script }} 2>&1 | logger -t backup"
|
||||||
cron_file: "ansible_restic_backup"
|
cron_file: "ansible_restic_backup"
|
||||||
user: "root"
|
user: "root"
|
||||||
|
@ -1,26 +0,0 @@
|
|||||||
---
|
|
||||||
- name: "Install and configure Caddy server"
|
|
||||||
hosts: all
|
|
||||||
|
|
||||||
vars_files:
|
|
||||||
- vars/ports.yml
|
|
||||||
- vars/vars.yml
|
|
||||||
|
|
||||||
tasks:
|
|
||||||
- name: "Ensure networkd service is started (required by Caddy)."
|
|
||||||
ansible.builtin.systemd:
|
|
||||||
name: systemd-networkd
|
|
||||||
state: started
|
|
||||||
enabled: true
|
|
||||||
|
|
||||||
- name: "Install and configure Caddy server"
|
|
||||||
ansible.builtin.import_role:
|
|
||||||
name: caddy_ansible.caddy_ansible
|
|
||||||
vars:
|
|
||||||
caddy_github_token: "{{ caddy_vars.github_token }}"
|
|
||||||
caddy_config: '{{ lookup("template", "templates/Caddyfile.j2") }}'
|
|
||||||
caddy_setcap: true
|
|
||||||
caddy_systemd_capabilities_enabled: true
|
|
||||||
caddy_systemd_capabilities: "CAP_NET_BIND_SERVICE"
|
|
||||||
# Поменяй на true, чтобы обновить Caddy
|
|
||||||
caddy_update: false
|
|
72
playbook-caddyproxy.yml
Normal file
72
playbook-caddyproxy.yml
Normal file
@ -0,0 +1,72 @@
|
|||||||
|
---
|
||||||
|
- name: "Configure caddy reverse proxy service"
|
||||||
|
hosts: all
|
||||||
|
|
||||||
|
vars_files:
|
||||||
|
- vars/ports.yml
|
||||||
|
- vars/secrets.yml
|
||||||
|
|
||||||
|
vars:
|
||||||
|
app_name: "caddyproxy"
|
||||||
|
app_user: "{{ app_name }}"
|
||||||
|
base_dir: "/home/{{ app_user }}"
|
||||||
|
|
||||||
|
data_dir: "{{ (base_dir, 'data') | path_join }}"
|
||||||
|
config_dir: "{{ (base_dir, 'config') | path_join }}"
|
||||||
|
caddy_file_dir: "{{ (base_dir, 'caddy_file') | path_join }}"
|
||||||
|
|
||||||
|
service_name: "{{ app_name }}"
|
||||||
|
|
||||||
|
tasks:
|
||||||
|
- name: "Create user and environment"
|
||||||
|
ansible.builtin.import_role:
|
||||||
|
name: owner
|
||||||
|
vars:
|
||||||
|
owner_name: "{{ app_user }}"
|
||||||
|
owner_extra_groups:
|
||||||
|
- "docker"
|
||||||
|
|
||||||
|
- name: "Create internal application directories"
|
||||||
|
ansible.builtin.file:
|
||||||
|
path: "{{ item }}"
|
||||||
|
state: "directory"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0770"
|
||||||
|
loop:
|
||||||
|
- "{{ data_dir }}"
|
||||||
|
- "{{ config_dir }}"
|
||||||
|
- "{{ caddy_file_dir }}"
|
||||||
|
|
||||||
|
- name: "Copy caddy file"
|
||||||
|
ansible.builtin.template:
|
||||||
|
src: "./files/{{ app_name }}/Caddyfile.j2"
|
||||||
|
dest: "{{ (caddy_file_dir, 'Caddyfile') | path_join }}"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0640"
|
||||||
|
|
||||||
|
- name: "Copy docker compose file"
|
||||||
|
ansible.builtin.template:
|
||||||
|
src: "./files/{{ app_name }}/docker-compose.yml.j2"
|
||||||
|
dest: "{{ base_dir }}/docker-compose.yml"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0640"
|
||||||
|
|
||||||
|
- name: "Run application with docker compose"
|
||||||
|
community.docker.docker_compose_v2:
|
||||||
|
project_src: "{{ base_dir }}"
|
||||||
|
state: "present"
|
||||||
|
remove_orphans: true
|
||||||
|
|
||||||
|
# - name: "Reload caddy"
|
||||||
|
# community.docker.docker_compose_v2_exec:
|
||||||
|
# project_src: '{{ base_dir }}'
|
||||||
|
# service: "{{ service_name }}"
|
||||||
|
# command: caddy reload --config /etc/caddy/Caddyfile
|
||||||
|
|
||||||
|
- name: "Restart application with docker compose"
|
||||||
|
community.docker.docker_compose_v2:
|
||||||
|
project_src: "{{ base_dir }}"
|
||||||
|
state: "restarted"
|
@ -4,7 +4,7 @@
|
|||||||
|
|
||||||
vars_files:
|
vars_files:
|
||||||
- vars/ports.yml
|
- vars/ports.yml
|
||||||
- vars/vars.yml
|
- vars/secrets.yml
|
||||||
|
|
||||||
tasks:
|
tasks:
|
||||||
- name: "Install python docker lib from pip"
|
- name: "Install python docker lib from pip"
|
||||||
@ -26,3 +26,8 @@
|
|||||||
- name: "Login to yandex docker registry."
|
- name: "Login to yandex docker registry."
|
||||||
ansible.builtin.script:
|
ansible.builtin.script:
|
||||||
cmd: "files/yandex-docker-registry-auth.sh"
|
cmd: "files/yandex-docker-registry-auth.sh"
|
||||||
|
|
||||||
|
- name: Create a network for web proxy
|
||||||
|
community.docker.docker_network:
|
||||||
|
name: "{{ web_proxy_network }}"
|
||||||
|
driver: "bridge"
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
|
|
||||||
vars_files:
|
vars_files:
|
||||||
- vars/ports.yml
|
- vars/ports.yml
|
||||||
- vars/vars.yml
|
- vars/secrets.yml
|
||||||
|
|
||||||
# See: https://github.com/zyedidia/eget/releases
|
# See: https://github.com/zyedidia/eget/releases
|
||||||
|
|
||||||
|
@ -4,12 +4,13 @@
|
|||||||
|
|
||||||
vars_files:
|
vars_files:
|
||||||
- vars/ports.yml
|
- vars/ports.yml
|
||||||
- vars/vars.yml
|
- vars/secrets.yml
|
||||||
|
|
||||||
vars:
|
vars:
|
||||||
app_name: "gitea"
|
app_name: "gitea"
|
||||||
app_user: "{{ app_name }}"
|
app_user: "{{ app_name }}"
|
||||||
base_dir: "/home/{{ app_name }}"
|
base_dir: "/home/{{ app_user }}"
|
||||||
|
data_dir: "{{ (base_dir, 'data') | path_join }}"
|
||||||
backups_dir: "{{ (base_dir, 'backups') | path_join }}"
|
backups_dir: "{{ (base_dir, 'backups') | path_join }}"
|
||||||
|
|
||||||
tasks:
|
tasks:
|
||||||
@ -22,13 +23,6 @@
|
|||||||
- "docker"
|
- "docker"
|
||||||
owner_ssh_keys:
|
owner_ssh_keys:
|
||||||
- "{{ lookup('file', 'files/av_id_rsa.pub') }}"
|
- "{{ lookup('file', 'files/av_id_rsa.pub') }}"
|
||||||
owner_env:
|
|
||||||
PROJECT_NAME: "{{ app_name }}"
|
|
||||||
DOCKER_PREFIX: "{{ app_name }}"
|
|
||||||
IMAGE_PREFIX: "{{ app_name }}"
|
|
||||||
CONTAINER_PREFIX: "{{ app_name }}"
|
|
||||||
USER_UID: "{{ user_create_result.uid }}"
|
|
||||||
USER_GID: "{{ user_create_result.group }}"
|
|
||||||
|
|
||||||
- name: "Create internal application directories"
|
- name: "Create internal application directories"
|
||||||
ansible.builtin.file:
|
ansible.builtin.file:
|
||||||
@ -36,15 +30,15 @@
|
|||||||
state: "directory"
|
state: "directory"
|
||||||
owner: "{{ app_user }}"
|
owner: "{{ app_user }}"
|
||||||
group: "{{ app_user }}"
|
group: "{{ app_user }}"
|
||||||
mode: "0775"
|
mode: "0770"
|
||||||
loop:
|
loop:
|
||||||
- "{{ (base_dir, 'data') | path_join }}"
|
- "{{ data_dir }}"
|
||||||
- "{{ backups_dir }}"
|
- "{{ backups_dir }}"
|
||||||
|
|
||||||
- name: "Copy gitea-dump script"
|
- name: "Copy backup script"
|
||||||
ansible.builtin.template:
|
ansible.builtin.template:
|
||||||
src: "files/{{ app_name }}/gitea-dump.sh.j2"
|
src: "files/{{ app_name }}/backup.sh.j2"
|
||||||
dest: "{{ base_dir }}/gitea-dump.sh"
|
dest: "{{ base_dir }}/backup.sh"
|
||||||
owner: "{{ app_user }}"
|
owner: "{{ app_user }}"
|
||||||
group: "{{ app_user }}"
|
group: "{{ app_user }}"
|
||||||
mode: "0750"
|
mode: "0750"
|
||||||
@ -55,7 +49,7 @@
|
|||||||
dest: "{{ base_dir }}/docker-compose.yml"
|
dest: "{{ base_dir }}/docker-compose.yml"
|
||||||
owner: "{{ app_user }}"
|
owner: "{{ app_user }}"
|
||||||
group: "{{ app_user }}"
|
group: "{{ app_user }}"
|
||||||
mode: "0644"
|
mode: "0640"
|
||||||
|
|
||||||
- name: "Run application with docker compose"
|
- name: "Run application with docker compose"
|
||||||
community.docker.docker_compose_v2:
|
community.docker.docker_compose_v2:
|
||||||
|
@ -4,31 +4,61 @@
|
|||||||
|
|
||||||
vars_files:
|
vars_files:
|
||||||
- vars/ports.yml
|
- vars/ports.yml
|
||||||
- vars/vars.yml
|
- vars/secrets.yml
|
||||||
|
|
||||||
vars:
|
vars:
|
||||||
app_name: "gramps"
|
app_name: "gramps"
|
||||||
base_dir: "/home/{{ primary_user }}/applications/{{ app_name }}/"
|
app_user: "{{ app_name }}"
|
||||||
|
base_dir: "/home/{{ app_user }}"
|
||||||
|
data_dir: "{{ (base_dir, 'data') | path_join }}"
|
||||||
|
backups_dir: "{{ (base_dir, 'backups') | path_join }}"
|
||||||
|
gobackup_config: "{{ (base_dir, 'gobackup.yml') | path_join }}"
|
||||||
|
|
||||||
tasks:
|
tasks:
|
||||||
- name: "Create application directories"
|
- name: "Create user and environment"
|
||||||
|
ansible.builtin.import_role:
|
||||||
|
name: owner
|
||||||
|
vars:
|
||||||
|
owner_name: "{{ app_user }}"
|
||||||
|
owner_extra_groups:
|
||||||
|
- "docker"
|
||||||
|
owner_ssh_keys:
|
||||||
|
- "{{ lookup('file', 'files/av_id_rsa.pub') }}"
|
||||||
|
|
||||||
|
- name: "Create application internal directories"
|
||||||
ansible.builtin.file:
|
ansible.builtin.file:
|
||||||
path: "{{ item }}"
|
path: "{{ item }}"
|
||||||
state: "directory"
|
state: "directory"
|
||||||
owner: "{{ primary_user }}"
|
owner: "{{ app_user }}"
|
||||||
group: "{{ primary_user }}"
|
group: "{{ app_user }}"
|
||||||
mode: "0755"
|
mode: "0750"
|
||||||
loop:
|
loop:
|
||||||
- "{{ base_dir }}"
|
- "{{ data_dir }}"
|
||||||
- '{{ (base_dir, "data") | path_join }}'
|
- "{{ backups_dir }}"
|
||||||
|
|
||||||
|
- name: "Copy gobackup config"
|
||||||
|
ansible.builtin.template:
|
||||||
|
src: "./files/{{ app_name }}/gobackup.yml.j2"
|
||||||
|
dest: "{{ gobackup_config }}"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0640"
|
||||||
|
|
||||||
|
- name: "Copy backup script"
|
||||||
|
ansible.builtin.template:
|
||||||
|
src: "files/{{ app_name }}/backup.sh.j2"
|
||||||
|
dest: "{{ base_dir }}/backup.sh"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0750"
|
||||||
|
|
||||||
- name: "Copy docker compose file"
|
- name: "Copy docker compose file"
|
||||||
ansible.builtin.template:
|
ansible.builtin.template:
|
||||||
src: "./files/{{ app_name }}/docker-compose.yml.j2"
|
src: "./files/{{ app_name }}/docker-compose.yml.j2"
|
||||||
dest: "{{ base_dir }}/docker-compose.yml"
|
dest: "{{ base_dir }}/docker-compose.yml"
|
||||||
owner: "{{ primary_user }}"
|
owner: "{{ app_user }}"
|
||||||
group: "{{ primary_user }}"
|
group: "{{ app_user }}"
|
||||||
mode: "0644"
|
mode: "0640"
|
||||||
|
|
||||||
- name: "Run application with docker compose"
|
- name: "Run application with docker compose"
|
||||||
community.docker.docker_compose_v2:
|
community.docker.docker_compose_v2:
|
||||||
|
67
playbook-homepage.yml
Normal file
67
playbook-homepage.yml
Normal file
@ -0,0 +1,67 @@
|
|||||||
|
---
|
||||||
|
# Play 1: Setup environment for the application
|
||||||
|
- name: "Setup environment for homepage application"
|
||||||
|
hosts: all
|
||||||
|
vars_files:
|
||||||
|
- vars/ports.yml
|
||||||
|
- vars/secrets.yml
|
||||||
|
- vars/homepage.yml
|
||||||
|
tags:
|
||||||
|
- setup
|
||||||
|
tasks:
|
||||||
|
- name: "Create user and environment"
|
||||||
|
ansible.builtin.import_role:
|
||||||
|
name: owner
|
||||||
|
vars:
|
||||||
|
owner_name: "{{ app_user }}"
|
||||||
|
owner_extra_groups:
|
||||||
|
- "docker"
|
||||||
|
owner_ssh_keys:
|
||||||
|
- "{{ lookup('file', 'files/av_id_rsa.pub') }}"
|
||||||
|
|
||||||
|
- name: "Login to yandex docker registry."
|
||||||
|
ansible.builtin.script:
|
||||||
|
cmd: "files/yandex-docker-registry-auth.sh"
|
||||||
|
|
||||||
|
# Play 2: Deploy the application
|
||||||
|
- name: "Deploy homepage application"
|
||||||
|
hosts: all
|
||||||
|
vars_files:
|
||||||
|
- vars/ports.yml
|
||||||
|
- vars/secrets.yml
|
||||||
|
- vars/homepage.yml
|
||||||
|
tags:
|
||||||
|
- deploy
|
||||||
|
tasks:
|
||||||
|
- name: "Check is web service image passed"
|
||||||
|
ansible.builtin.assert:
|
||||||
|
that:
|
||||||
|
- "homepage_web_image is defined"
|
||||||
|
fail_msg: 'You must pass variable "homepage_web_image"'
|
||||||
|
|
||||||
|
- name: "Create full image name with container registry"
|
||||||
|
ansible.builtin.set_fact:
|
||||||
|
registry_homepage_web_image: "{{ (docker_registry_prefix, homepage_web_image) | path_join }}"
|
||||||
|
|
||||||
|
- name: "Push web service image to remote registry"
|
||||||
|
community.docker.docker_image:
|
||||||
|
state: present
|
||||||
|
source: local
|
||||||
|
name: "{{ homepage_web_image }}"
|
||||||
|
repository: "{{ registry_homepage_web_image }}"
|
||||||
|
push: true
|
||||||
|
delegate_to: 127.0.0.1
|
||||||
|
|
||||||
|
- name: "Copy docker compose file"
|
||||||
|
ansible.builtin.template:
|
||||||
|
src: "./files/{{ app_name }}/docker-compose.yml.j2"
|
||||||
|
dest: "{{ base_dir }}/docker-compose.yml"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0640"
|
||||||
|
|
||||||
|
- name: "Run application with docker compose"
|
||||||
|
community.docker.docker_compose_v2:
|
||||||
|
project_src: "{{ base_dir }}"
|
||||||
|
state: "present"
|
||||||
|
remove_orphans: true
|
@ -1,15 +1,18 @@
|
|||||||
---
|
---
|
||||||
- name: "Configure keycloak application"
|
- name: "Configure miniflux application"
|
||||||
hosts: all
|
hosts: all
|
||||||
|
|
||||||
vars_files:
|
vars_files:
|
||||||
- vars/ports.yml
|
- vars/ports.yml
|
||||||
- vars/vars.yml
|
- vars/secrets.yml
|
||||||
|
|
||||||
vars:
|
vars:
|
||||||
app_name: "keycloak"
|
app_name: "miniflux"
|
||||||
app_user: "{{ app_name }}"
|
app_user: "{{ app_name }}"
|
||||||
base_dir: "/home/{{ app_name }}"
|
base_dir: "/home/{{ app_user }}"
|
||||||
|
data_dir: "{{ (base_dir, 'data') | path_join }}"
|
||||||
|
postgres_data_dir: "{{ (base_dir, 'data', 'postgres') | path_join }}"
|
||||||
|
postgres_backups_dir: "{{ (base_dir, 'backups', 'postgres') | path_join }}"
|
||||||
|
|
||||||
tasks:
|
tasks:
|
||||||
- name: "Create user and environment"
|
- name: "Create user and environment"
|
||||||
@ -17,25 +20,17 @@
|
|||||||
name: owner
|
name: owner
|
||||||
vars:
|
vars:
|
||||||
owner_name: "{{ app_user }}"
|
owner_name: "{{ app_user }}"
|
||||||
owner_extra_groups:
|
owner_extra_groups: ["docker"]
|
||||||
- "docker"
|
|
||||||
owner_ssh_keys:
|
|
||||||
- "{{ lookup('file', 'files/av_id_rsa.pub') }}"
|
|
||||||
owner_env:
|
|
||||||
PROJECT_NAME: "{{ app_name }}"
|
|
||||||
DOCKER_PREFIX: "{{ app_name }}"
|
|
||||||
IMAGE_PREFIX: "{{ app_name }}"
|
|
||||||
CONTAINER_PREFIX: "{{ app_name }}"
|
|
||||||
USER_UID: "{{ user_create_result.uid }}"
|
|
||||||
USER_GID: "{{ user_create_result.group }}"
|
|
||||||
|
|
||||||
- name: "Create application data directory"
|
- name: "Create internal directories"
|
||||||
ansible.builtin.file:
|
ansible.builtin.file:
|
||||||
path: "{{ (base_dir, 'data') | path_join }}"
|
path: "{{ item }}"
|
||||||
state: "directory"
|
state: "directory"
|
||||||
owner: "{{ app_user }}"
|
owner: "{{ app_user }}"
|
||||||
group: "{{ app_user }}"
|
group: "{{ app_user }}"
|
||||||
mode: "0777"
|
mode: "0770"
|
||||||
|
loop:
|
||||||
|
- "{{ postgres_backups_dir }}"
|
||||||
|
|
||||||
- name: "Copy docker compose file"
|
- name: "Copy docker compose file"
|
||||||
ansible.builtin.template:
|
ansible.builtin.template:
|
||||||
@ -43,7 +38,15 @@
|
|||||||
dest: "{{ base_dir }}/docker-compose.yml"
|
dest: "{{ base_dir }}/docker-compose.yml"
|
||||||
owner: "{{ app_user }}"
|
owner: "{{ app_user }}"
|
||||||
group: "{{ app_user }}"
|
group: "{{ app_user }}"
|
||||||
mode: "0644"
|
mode: "0640"
|
||||||
|
|
||||||
|
- name: "Copy backup script"
|
||||||
|
ansible.builtin.template:
|
||||||
|
src: "./files/{{ app_name }}/backup.sh.j2"
|
||||||
|
dest: "{{ base_dir }}/backup.sh"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0750"
|
||||||
|
|
||||||
- name: "Run application with docker compose"
|
- name: "Run application with docker compose"
|
||||||
community.docker.docker_compose_v2:
|
community.docker.docker_compose_v2:
|
@ -4,14 +4,84 @@
|
|||||||
|
|
||||||
vars_files:
|
vars_files:
|
||||||
- vars/ports.yml
|
- vars/ports.yml
|
||||||
- vars/vars.yml
|
- vars/secrets.yml
|
||||||
|
|
||||||
|
vars:
|
||||||
|
app_name: "netdata"
|
||||||
|
app_user: "{{ app_name }}"
|
||||||
|
base_dir: "/home/{{ app_user }}"
|
||||||
|
config_dir: "{{ (base_dir, 'config') | path_join }}"
|
||||||
|
config_go_d_dir: "{{ (config_dir, 'go.d') | path_join }}"
|
||||||
|
data_dir: "{{ (base_dir, 'data') | path_join }}"
|
||||||
|
|
||||||
tasks:
|
tasks:
|
||||||
- name: "Install Netdata from role"
|
- name: "Create user and environment"
|
||||||
ansible.builtin.import_role:
|
ansible.builtin.import_role:
|
||||||
name: netdata
|
name: owner
|
||||||
vars:
|
vars:
|
||||||
netdata_version: "v2.4.0"
|
owner_name: "{{ app_user }}"
|
||||||
netdata_exposed_port: "{{ netdata_port }}"
|
owner_extra_groups: ["docker"]
|
||||||
tags:
|
|
||||||
- monitoring
|
- name: "Create internal application directories"
|
||||||
|
ansible.builtin.file:
|
||||||
|
path: "{{ item }}"
|
||||||
|
state: "directory"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0770"
|
||||||
|
loop:
|
||||||
|
- "{{ config_dir }}"
|
||||||
|
- "{{ config_go_d_dir }}"
|
||||||
|
- "{{ data_dir }}"
|
||||||
|
|
||||||
|
- name: "Copy netdata config file"
|
||||||
|
ansible.builtin.template:
|
||||||
|
src: "files/{{ app_name }}/netdata.conf.j2"
|
||||||
|
dest: "{{ config_dir }}/netdata.conf"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0640"
|
||||||
|
|
||||||
|
- name: "Copy prometheus plugin config file"
|
||||||
|
ansible.builtin.copy:
|
||||||
|
src: "files/{{ app_name }}/go.d/prometheus.conf"
|
||||||
|
dest: "{{ config_go_d_dir }}/prometheus.conf"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0640"
|
||||||
|
|
||||||
|
- name: "Copy fail2ban plugin config file"
|
||||||
|
ansible.builtin.copy:
|
||||||
|
src: "files/{{ app_name }}/go.d/fail2ban.conf"
|
||||||
|
dest: "{{ config_go_d_dir }}/fail2ban.conf"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0640"
|
||||||
|
|
||||||
|
- name: "Grab docker group id."
|
||||||
|
ansible.builtin.shell:
|
||||||
|
cmd: |
|
||||||
|
set -o pipefail
|
||||||
|
grep docker /etc/group | cut -d ':' -f 3
|
||||||
|
executable: /bin/bash
|
||||||
|
register: netdata_docker_group_output
|
||||||
|
changed_when: netdata_docker_group_output.rc != 0
|
||||||
|
|
||||||
|
- name: "Copy docker compose file"
|
||||||
|
ansible.builtin.template:
|
||||||
|
src: "./files/{{ app_name }}/docker-compose.yml.j2"
|
||||||
|
dest: "{{ base_dir }}/docker-compose.yml"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0640"
|
||||||
|
|
||||||
|
- name: "Run application with docker compose"
|
||||||
|
community.docker.docker_compose_v2:
|
||||||
|
project_src: "{{ base_dir }}"
|
||||||
|
state: "present"
|
||||||
|
remove_orphans: true
|
||||||
|
|
||||||
|
- name: "Restart application with docker compose"
|
||||||
|
community.docker.docker_compose_v2:
|
||||||
|
project_src: "{{ base_dir }}"
|
||||||
|
state: "restarted"
|
||||||
|
@ -4,14 +4,15 @@
|
|||||||
|
|
||||||
vars_files:
|
vars_files:
|
||||||
- vars/ports.yml
|
- vars/ports.yml
|
||||||
- vars/vars.yml
|
- vars/secrets.yml
|
||||||
|
|
||||||
vars:
|
vars:
|
||||||
app_name: "outline"
|
app_name: "outline"
|
||||||
app_user: "{{ app_name }}"
|
app_user: "{{ app_name }}"
|
||||||
base_dir: "/home/{{ app_name }}"
|
base_dir: "/home/{{ app_user }}"
|
||||||
data_dir: "{{ (base_dir, 'data') | path_join }}"
|
data_dir: "{{ (base_dir, 'data') | path_join }}"
|
||||||
backups_dir: "{{ (base_dir, 'backups') | path_join }}"
|
postgres_data_dir: "{{ (base_dir, 'data', 'postgres') | path_join }}"
|
||||||
|
postgres_backups_dir: "{{ (base_dir, 'backups', 'postgres') | path_join }}"
|
||||||
|
|
||||||
tasks:
|
tasks:
|
||||||
- name: "Create user and environment"
|
- name: "Create user and environment"
|
||||||
@ -23,13 +24,16 @@
|
|||||||
- "docker"
|
- "docker"
|
||||||
owner_ssh_keys:
|
owner_ssh_keys:
|
||||||
- "{{ lookup('file', 'files/av_id_rsa.pub') }}"
|
- "{{ lookup('file', 'files/av_id_rsa.pub') }}"
|
||||||
owner_env:
|
|
||||||
PROJECT_NAME: "{{ app_name }}"
|
- name: "Create internal directories"
|
||||||
DOCKER_PREFIX: "{{ app_name }}"
|
ansible.builtin.file:
|
||||||
IMAGE_PREFIX: "{{ app_name }}"
|
path: "{{ item }}"
|
||||||
CONTAINER_PREFIX: "{{ app_name }}"
|
state: "directory"
|
||||||
USER_UID: "{{ user_create_result.uid }}"
|
owner: "{{ app_user }}"
|
||||||
USER_GID: "{{ user_create_result.group }}"
|
group: "{{ app_user }}"
|
||||||
|
mode: "0770"
|
||||||
|
loop:
|
||||||
|
- "{{ postgres_backups_dir }}"
|
||||||
|
|
||||||
- name: "Copy docker compose file"
|
- name: "Copy docker compose file"
|
||||||
ansible.builtin.template:
|
ansible.builtin.template:
|
||||||
@ -37,7 +41,15 @@
|
|||||||
dest: "{{ base_dir }}/docker-compose.yml"
|
dest: "{{ base_dir }}/docker-compose.yml"
|
||||||
owner: "{{ app_user }}"
|
owner: "{{ app_user }}"
|
||||||
group: "{{ app_user }}"
|
group: "{{ app_user }}"
|
||||||
mode: "0644"
|
mode: "0640"
|
||||||
|
|
||||||
|
- name: "Copy backup script"
|
||||||
|
ansible.builtin.template:
|
||||||
|
src: "./files/{{ app_name }}/backup.sh.j2"
|
||||||
|
dest: "{{ base_dir }}/backup.sh"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0750"
|
||||||
|
|
||||||
- name: "Run application with docker compose"
|
- name: "Run application with docker compose"
|
||||||
community.docker.docker_compose_v2:
|
community.docker.docker_compose_v2:
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
|
|
||||||
vars_files:
|
vars_files:
|
||||||
- vars/ports.yml
|
- vars/ports.yml
|
||||||
- vars/vars.yml
|
- vars/secrets.yml
|
||||||
|
|
||||||
vars:
|
vars:
|
||||||
user_name: "<put-name-here>"
|
user_name: "<put-name-here>"
|
||||||
@ -25,3 +25,8 @@
|
|||||||
ansible.builtin.file:
|
ansible.builtin.file:
|
||||||
path: "/var/www/{{ user_name }}"
|
path: "/var/www/{{ user_name }}"
|
||||||
state: absent
|
state: absent
|
||||||
|
|
||||||
|
- name: "Remove home dir"
|
||||||
|
ansible.builtin.file:
|
||||||
|
path: "/home/{{ user_name }}"
|
||||||
|
state: absent
|
||||||
|
34
playbook-rssbridge.yml
Normal file
34
playbook-rssbridge.yml
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
---
|
||||||
|
- name: "Configure rssbridge application"
|
||||||
|
hosts: all
|
||||||
|
|
||||||
|
vars_files:
|
||||||
|
- vars/ports.yml
|
||||||
|
- vars/secrets.yml
|
||||||
|
|
||||||
|
vars:
|
||||||
|
app_name: "rssbridge"
|
||||||
|
app_user: "{{ app_name }}"
|
||||||
|
base_dir: "/home/{{ app_user }}"
|
||||||
|
|
||||||
|
tasks:
|
||||||
|
- name: "Create user and environment"
|
||||||
|
ansible.builtin.import_role:
|
||||||
|
name: owner
|
||||||
|
vars:
|
||||||
|
owner_name: "{{ app_user }}"
|
||||||
|
owner_extra_groups: ["docker"]
|
||||||
|
|
||||||
|
- name: "Copy docker compose file"
|
||||||
|
ansible.builtin.template:
|
||||||
|
src: "./files/{{ app_name }}/docker-compose.yml.j2"
|
||||||
|
dest: "{{ base_dir }}/docker-compose.yml"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0640"
|
||||||
|
|
||||||
|
- name: "Run application with docker compose"
|
||||||
|
community.docker.docker_compose_v2:
|
||||||
|
project_src: "{{ base_dir }}"
|
||||||
|
state: "present"
|
||||||
|
remove_orphans: true
|
@ -4,7 +4,7 @@
|
|||||||
|
|
||||||
vars_files:
|
vars_files:
|
||||||
- vars/ports.yml
|
- vars/ports.yml
|
||||||
- vars/vars.yml
|
- vars/secrets.yml
|
||||||
|
|
||||||
vars:
|
vars:
|
||||||
apt_packages:
|
apt_packages:
|
||||||
@ -25,21 +25,13 @@
|
|||||||
name: "{{ apt_packages }}"
|
name: "{{ apt_packages }}"
|
||||||
update_cache: true
|
update_cache: true
|
||||||
|
|
||||||
- name: "Configure timezone"
|
|
||||||
ansible.builtin.import_role:
|
|
||||||
name: yatesr.timezone
|
|
||||||
vars:
|
|
||||||
timezone: UTC
|
|
||||||
tags:
|
|
||||||
- skip_ansible_lint
|
|
||||||
|
|
||||||
- name: "Configure security settings"
|
- name: "Configure security settings"
|
||||||
ansible.builtin.import_role:
|
ansible.builtin.import_role:
|
||||||
name: geerlingguy.security
|
name: geerlingguy.security
|
||||||
vars:
|
vars:
|
||||||
security_ssh_permit_root_login: "yes"
|
security_ssh_permit_root_login: "yes"
|
||||||
security_autoupdate_enabled: "no"
|
security_autoupdate_enabled: "no"
|
||||||
security_fail2ban_enabled: "yes"
|
security_fail2ban_enabled: true
|
||||||
|
|
||||||
- name: "Copy keep files script"
|
- name: "Copy keep files script"
|
||||||
ansible.builtin.copy:
|
ansible.builtin.copy:
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
|
|
||||||
vars_files:
|
vars_files:
|
||||||
- vars/ports.yml
|
- vars/ports.yml
|
||||||
- vars/vars.yml
|
- vars/secrets.yml
|
||||||
|
|
||||||
tasks:
|
tasks:
|
||||||
- name: Perform an upgrade of packages
|
- name: Perform an upgrade of packages
|
||||||
|
64
playbook-wakapi.yml
Normal file
64
playbook-wakapi.yml
Normal file
@ -0,0 +1,64 @@
|
|||||||
|
---
|
||||||
|
- name: "Configure wakapi application"
|
||||||
|
hosts: all
|
||||||
|
|
||||||
|
vars_files:
|
||||||
|
- vars/ports.yml
|
||||||
|
- vars/secrets.yml
|
||||||
|
|
||||||
|
vars:
|
||||||
|
app_name: "wakapi"
|
||||||
|
app_user: "{{ app_name }}"
|
||||||
|
base_dir: "/home/{{ app_user }}"
|
||||||
|
data_dir: "{{ (base_dir, 'data') | path_join }}"
|
||||||
|
backups_dir: "{{ (base_dir, 'backups') | path_join }}"
|
||||||
|
gobackup_config: "{{ (base_dir, 'gobackup.yml') | path_join }}"
|
||||||
|
|
||||||
|
tasks:
|
||||||
|
- name: "Create user and environment"
|
||||||
|
ansible.builtin.import_role:
|
||||||
|
name: owner
|
||||||
|
vars:
|
||||||
|
owner_name: "{{ app_user }}"
|
||||||
|
owner_extra_groups: ["docker"]
|
||||||
|
|
||||||
|
- name: "Create application internal directories"
|
||||||
|
ansible.builtin.file:
|
||||||
|
path: "{{ item }}"
|
||||||
|
state: "directory"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0750"
|
||||||
|
loop:
|
||||||
|
- "{{ data_dir }}"
|
||||||
|
- "{{ backups_dir }}"
|
||||||
|
|
||||||
|
- name: "Copy gobackup config"
|
||||||
|
ansible.builtin.template:
|
||||||
|
src: "./files/{{ app_name }}/gobackup.yml.j2"
|
||||||
|
dest: "{{ gobackup_config }}"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0640"
|
||||||
|
|
||||||
|
- name: "Copy backup script"
|
||||||
|
ansible.builtin.template:
|
||||||
|
src: "files/{{ app_name }}/backup.sh.j2"
|
||||||
|
dest: "{{ base_dir }}/backup.sh"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0750"
|
||||||
|
|
||||||
|
- name: "Copy docker compose file"
|
||||||
|
ansible.builtin.template:
|
||||||
|
src: "./files/{{ app_name }}/docker-compose.yml.j2"
|
||||||
|
dest: "{{ base_dir }}/docker-compose.yml"
|
||||||
|
owner: "{{ app_user }}"
|
||||||
|
group: "{{ app_user }}"
|
||||||
|
mode: "0640"
|
||||||
|
|
||||||
|
- name: "Run application with docker compose"
|
||||||
|
community.docker.docker_compose_v2:
|
||||||
|
project_src: "{{ base_dir }}"
|
||||||
|
state: "present"
|
||||||
|
remove_orphans: true
|
@ -2,6 +2,6 @@
|
|||||||
ungrouped:
|
ungrouped:
|
||||||
hosts:
|
hosts:
|
||||||
server:
|
server:
|
||||||
ansible_host: '158.160.46.255'
|
ansible_host: "158.160.46.255"
|
||||||
ansible_user: 'major'
|
ansible_user: "major"
|
||||||
ansible_become: true
|
ansible_become: true
|
||||||
|
@ -3,10 +3,7 @@
|
|||||||
version: 1.2.2
|
version: 1.2.2
|
||||||
|
|
||||||
- src: geerlingguy.security
|
- src: geerlingguy.security
|
||||||
version: 2.4.0
|
version: 3.0.0
|
||||||
|
|
||||||
- src: geerlingguy.docker
|
- src: geerlingguy.docker
|
||||||
version: 7.4.3
|
version: 7.4.7
|
||||||
|
|
||||||
- src: caddy_ansible.caddy_ansible
|
|
||||||
version: v3.2.0
|
|
||||||
|
@ -1,18 +0,0 @@
|
|||||||
---
|
|
||||||
- name: 'Create owner.'
|
|
||||||
import_role:
|
|
||||||
name: owner
|
|
||||||
vars:
|
|
||||||
owner_name: '{{ username }}'
|
|
||||||
owner_group: '{{ username }}'
|
|
||||||
owner_extra_groups: '{{ extra_groups | default([]) }}'
|
|
||||||
owner_ssh_keys: '{{ ssh_keys | default([]) }}'
|
|
||||||
owner_env: '{{ env | default({}) }}'
|
|
||||||
|
|
||||||
- name: 'Create web dir.'
|
|
||||||
file:
|
|
||||||
path: '/var/www/{{ username }}'
|
|
||||||
state: directory
|
|
||||||
owner: '{{ username }}'
|
|
||||||
group: '{{ username }}'
|
|
||||||
recurse: True
|
|
@ -1,8 +1,8 @@
|
|||||||
---
|
---
|
||||||
# defaults file for eget
|
# defaults file for eget
|
||||||
eget_version: '1.3.4'
|
eget_version: "1.3.4"
|
||||||
eget_download_url: 'https://github.com/zyedidia/eget/releases/download/v{{ eget_version }}/eget-{{ eget_version }}-linux_amd64.tar.gz'
|
eget_download_url: "https://github.com/zyedidia/eget/releases/download/v{{ eget_version }}/eget-{{ eget_version }}-linux_amd64.tar.gz"
|
||||||
eget_install_path: '/usr/bin/eget'
|
eget_install_path: "/usr/bin/eget"
|
||||||
|
|
||||||
eget_download_dest: '/tmp/{{ eget_download_url | split("/") | last }}'
|
eget_download_dest: '/tmp/{{ eget_download_url | split("/") | last }}'
|
||||||
eget_unarchive_dest: '{{ eget_download_dest | regex_replace("(\.tar\.gz|\.zip)$", "") }}'
|
eget_unarchive_dest: '{{ eget_download_dest | regex_replace("(\.tar\.gz|\.zip)$", "") }}'
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
|
---
|
||||||
galaxy_info:
|
galaxy_info:
|
||||||
author: 'Anton Vakhrushev'
|
author: "Anton Vakhrushev"
|
||||||
description: 'Role for installation eget utility'
|
description: "Role for installation eget utility"
|
||||||
|
|
||||||
# If the issue tracker for your role is not on github, uncomment the
|
# If the issue tracker for your role is not on github, uncomment the
|
||||||
# next line and provide a value
|
# next line and provide a value
|
||||||
@ -13,9 +14,9 @@ galaxy_info:
|
|||||||
# - GPL-3.0-only
|
# - GPL-3.0-only
|
||||||
# - Apache-2.0
|
# - Apache-2.0
|
||||||
# - CC-BY-4.0
|
# - CC-BY-4.0
|
||||||
license: 'MIT'
|
license: "MIT"
|
||||||
|
|
||||||
min_ansible_version: '2.1'
|
min_ansible_version: "2.1"
|
||||||
|
|
||||||
# If this a Container Enabled role, provide the minimum Ansible Container version.
|
# If this a Container Enabled role, provide the minimum Ansible Container version.
|
||||||
# min_ansible_container_version:
|
# min_ansible_container_version:
|
||||||
|
@ -1,30 +1,30 @@
|
|||||||
---
|
---
|
||||||
- name: 'Download eget from url "{{ eget_download_url }}"'
|
- name: 'Download eget from url "{{ eget_download_url }}"'
|
||||||
ansible.builtin.get_url:
|
ansible.builtin.get_url:
|
||||||
url: '{{ eget_download_url }}'
|
url: "{{ eget_download_url }}"
|
||||||
dest: '{{ eget_download_dest }}'
|
dest: "{{ eget_download_dest }}"
|
||||||
mode: '0600'
|
mode: "0600"
|
||||||
|
|
||||||
- name: 'Unarchive eget'
|
- name: "Unarchive eget"
|
||||||
ansible.builtin.unarchive:
|
ansible.builtin.unarchive:
|
||||||
src: '{{ eget_download_dest }}'
|
src: "{{ eget_download_dest }}"
|
||||||
dest: '/tmp'
|
dest: "/tmp"
|
||||||
list_files: true
|
list_files: true
|
||||||
remote_src: true
|
remote_src: true
|
||||||
|
|
||||||
- name: 'Install eget binary'
|
- name: "Install eget binary"
|
||||||
ansible.builtin.copy:
|
ansible.builtin.copy:
|
||||||
src: '{{ (eget_unarchive_dest, "eget") | path_join }}'
|
src: '{{ (eget_unarchive_dest, "eget") | path_join }}'
|
||||||
dest: '{{ eget_install_path }}'
|
dest: "{{ eget_install_path }}"
|
||||||
mode: '0755'
|
mode: "0755"
|
||||||
remote_src: true
|
remote_src: true
|
||||||
|
|
||||||
- name: 'Remove temporary files'
|
- name: "Remove temporary files"
|
||||||
ansible.builtin.file:
|
ansible.builtin.file:
|
||||||
path: '{{ eget_download_dest }}'
|
path: "{{ eget_download_dest }}"
|
||||||
state: absent
|
state: absent
|
||||||
|
|
||||||
- name: 'Remove temporary directories'
|
- name: "Remove temporary directories"
|
||||||
ansible.builtin.file:
|
ansible.builtin.file:
|
||||||
path: '{{ eget_unarchive_dest }}'
|
path: "{{ eget_unarchive_dest }}"
|
||||||
state: absent
|
state: absent
|
||||||
|
@ -1,24 +1,24 @@
|
|||||||
---
|
---
|
||||||
# tasks file for eget
|
# tasks file for eget
|
||||||
|
|
||||||
- name: 'Check if eget installed'
|
- name: "Check if eget installed"
|
||||||
ansible.builtin.command:
|
ansible.builtin.command:
|
||||||
cmd: '{{ eget_install_path }} --version'
|
cmd: "{{ eget_install_path }} --version"
|
||||||
register: eget_installed_output
|
register: eget_installed_output
|
||||||
ignore_errors: true
|
ignore_errors: true
|
||||||
changed_when: false
|
changed_when: false
|
||||||
|
|
||||||
- name: 'Check eget installed version'
|
- name: "Check eget installed version"
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
eget_need_install: '{{ not (eget_installed_output.rc == 0 and eget_version in eget_installed_output.stdout) }}'
|
eget_need_install: "{{ not (eget_installed_output.rc == 0 and eget_version in eget_installed_output.stdout) }}"
|
||||||
|
|
||||||
- name: 'Assert that installation flag is defined'
|
- name: "Assert that installation flag is defined"
|
||||||
ansible.builtin.assert:
|
ansible.builtin.assert:
|
||||||
that:
|
that:
|
||||||
- eget_need_install is defined
|
- eget_need_install is defined
|
||||||
- eget_need_install is boolean
|
- eget_need_install is boolean
|
||||||
|
|
||||||
- name: 'Download eget and install eget'
|
- name: "Download eget and install eget"
|
||||||
ansible.builtin.include_tasks:
|
ansible.builtin.include_tasks:
|
||||||
file: 'install.yml'
|
file: "install.yml"
|
||||||
when: eget_need_install
|
when: eget_need_install
|
||||||
|
@ -1,4 +0,0 @@
|
|||||||
---
|
|
||||||
netdata_version: 'v2.0.0'
|
|
||||||
netdata_image: 'netdata/netdata:{{ netdata_version }}'
|
|
||||||
netdata_exposed_port: '19999'
|
|
@ -1,36 +0,0 @@
|
|||||||
---
|
|
||||||
- name: 'Grab docker group id.'
|
|
||||||
ansible.builtin.shell:
|
|
||||||
cmd: |
|
|
||||||
set -o pipefail
|
|
||||||
grep docker /etc/group | cut -d ':' -f 3
|
|
||||||
executable: /bin/bash
|
|
||||||
register: netdata_docker_group_output
|
|
||||||
changed_when: netdata_docker_group_output.rc != 0
|
|
||||||
|
|
||||||
- name: 'Create NetData container from {{ netdata_image }}'
|
|
||||||
community.docker.docker_container:
|
|
||||||
name: netdata
|
|
||||||
image: '{{ netdata_image }}'
|
|
||||||
image_name_mismatch: 'recreate'
|
|
||||||
restart_policy: 'always'
|
|
||||||
published_ports:
|
|
||||||
- '127.0.0.1:{{ netdata_exposed_port }}:19999'
|
|
||||||
volumes:
|
|
||||||
- '/:/host/root:ro,rslave'
|
|
||||||
- '/etc/group:/host/etc/group:ro'
|
|
||||||
- '/etc/localtime:/etc/localtime:ro'
|
|
||||||
- '/etc/os-release:/host/etc/os-release:ro'
|
|
||||||
- '/etc/passwd:/host/etc/passwd:ro'
|
|
||||||
- '/proc:/host/proc:ro'
|
|
||||||
- '/run/dbus:/run/dbus:ro'
|
|
||||||
- '/sys:/host/sys:ro'
|
|
||||||
- '/var/log:/host/var/log:ro'
|
|
||||||
- '/var/run/docker.sock:/var/run/docker.sock:ro'
|
|
||||||
capabilities:
|
|
||||||
- 'SYS_PTRACE'
|
|
||||||
- 'SYS_ADMIN'
|
|
||||||
security_opts:
|
|
||||||
- 'apparmor:unconfined'
|
|
||||||
env:
|
|
||||||
PGID: '{{ netdata_docker_group_output.stdout | default(999) }}'
|
|
@ -27,8 +27,7 @@
|
|||||||
|
|
||||||
- name: "Prepare env variables."
|
- name: "Prepare env variables."
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
env_dict: '{{ owner_env | combine({ "CURRENT_UID": user_create_result.uid | default(owner_name), "CURRENT_GID": user_create_result.group | default(owner_group)
|
env_dict: '{{ owner_env | combine({"USER_UID": user_create_result.uid, "USER_GID": user_create_result.group}) }}'
|
||||||
}) }}'
|
|
||||||
|
|
||||||
- name: 'Set up environment variables for user "{{ owner_name }}".'
|
- name: 'Set up environment variables for user "{{ owner_name }}".'
|
||||||
ansible.builtin.template:
|
ansible.builtin.template:
|
||||||
|
@ -1,67 +0,0 @@
|
|||||||
# -------------------------------------------------------------------
|
|
||||||
# Global options
|
|
||||||
# -------------------------------------------------------------------
|
|
||||||
{
|
|
||||||
grace_period 15s
|
|
||||||
}
|
|
||||||
|
|
||||||
# -------------------------------------------------------------------
|
|
||||||
# Netdata service
|
|
||||||
# -------------------------------------------------------------------
|
|
||||||
|
|
||||||
status.vakhrushev.me, :29999 {
|
|
||||||
tls anwinged@ya.ru
|
|
||||||
|
|
||||||
reverse_proxy {
|
|
||||||
to 127.0.0.1:{{ netdata_port }}
|
|
||||||
}
|
|
||||||
|
|
||||||
basicauth / {
|
|
||||||
{{ netdata.login }} {{ netdata.password_hash }}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
# -------------------------------------------------------------------
|
|
||||||
# Applications
|
|
||||||
# -------------------------------------------------------------------
|
|
||||||
|
|
||||||
vakhrushev.me {
|
|
||||||
tls anwinged@ya.ru
|
|
||||||
|
|
||||||
reverse_proxy {
|
|
||||||
to 127.0.0.1:{{ homepage_port }}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
git.vakhrushev.me {
|
|
||||||
tls anwinged@ya.ru
|
|
||||||
|
|
||||||
reverse_proxy {
|
|
||||||
to 127.0.0.1:{{ gitea_port }}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
kk.vakhrushev.me {
|
|
||||||
tls anwinged@ya.ru
|
|
||||||
|
|
||||||
reverse_proxy {
|
|
||||||
to 127.0.0.1:{{ keycloak_port }}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
outline.vakhrushev.me {
|
|
||||||
tls anwinged@ya.ru
|
|
||||||
|
|
||||||
reverse_proxy {
|
|
||||||
to 127.0.0.1:{{ outline_port }}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
gramps.vakhrushev.me {
|
|
||||||
tls anwinged@ya.ru
|
|
||||||
|
|
||||||
reverse_proxy {
|
|
||||||
to 127.0.0.1:{{ gramps_port }}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
7
vars/homepage.yml
Normal file
7
vars/homepage.yml
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
---
|
||||||
|
app_name: "homepage"
|
||||||
|
app_user: "{{ app_name }}"
|
||||||
|
base_dir: "/home/{{ app_user }}"
|
||||||
|
docker_registry_prefix: "cr.yandex/crplfk0168i4o8kd7ade"
|
||||||
|
|
||||||
|
homepage_web_image: "{{ homepage_web_image | default(omit) }}"
|
@ -3,6 +3,5 @@ base_port: 41080
|
|||||||
homepage_port: "{{ base_port + 3 }}"
|
homepage_port: "{{ base_port + 3 }}"
|
||||||
netdata_port: "{{ base_port + 4 }}"
|
netdata_port: "{{ base_port + 4 }}"
|
||||||
gitea_port: "{{ base_port + 8 }}"
|
gitea_port: "{{ base_port + 8 }}"
|
||||||
keycloak_port: "{{ base_port + 9 }}"
|
|
||||||
outline_port: "{{ base_port + 10 }}"
|
outline_port: "{{ base_port + 10 }}"
|
||||||
gramps_port: "{{ base_port + 12 }}"
|
gramps_port: "{{ base_port + 12 }}"
|
||||||
|
142
vars/secrets.yml
Normal file
142
vars/secrets.yml
Normal file
@ -0,0 +1,142 @@
|
|||||||
|
$ANSIBLE_VAULT;1.1;AES256
|
||||||
|
62653431636461623338643536653736633166303934626565363963373637396534303130373035
|
||||||
|
6565376162653735313737333439633862643366336264650a633265316463323062653032363861
|
||||||
|
32626536343138663837633334316537373662653262366163633334623764633938323363363962
|
||||||
|
6230333564643665320a613862653632363363616266336338346539323964383736366235306437
|
||||||
|
33306363353163383663643062656330313134353836666232616532316264303564336235356661
|
||||||
|
30653262363866653139646436333036393837383262643537313933613939326433313565393465
|
||||||
|
31373036353133663337613935343038616164316132303833363338623863633234656537653039
|
||||||
|
62626436346238636234393939366139363034306432326538656264343733356537393332633836
|
||||||
|
38636639626665666238656338363633383566616638353235383465623232646537616230626630
|
||||||
|
63303130316438353934656636393366306566346362356564393661643064323630636463383061
|
||||||
|
37636461386432323136393739633862313337333261306664323361393835323034643134383461
|
||||||
|
31313762616538336666656137373631336132383364646163633732323431613239333563653332
|
||||||
|
65616664333839363834333362626238633833666430653738613636333432333430333861356339
|
||||||
|
61323865663661383534343964346238383134613532616637346235616139383434623564333361
|
||||||
|
31636165653261363830623162623738333937316664633434346431626630393837366666643434
|
||||||
|
61643734653834326434353431393732376266626266313264376235323838313539306463653864
|
||||||
|
36393461366230643234376161623330326365616539323965633431633238386262373562383161
|
||||||
|
39323634633166643038356434616461613864303334393932663730303839373530643933323839
|
||||||
|
66353337326336656635636362356531613634623633303461336565363564393964663430393666
|
||||||
|
64326439346233346132653230343234653430653239636362616561636166343030303863373337
|
||||||
|
36363633646432613138313062346164663730313061363432396138323561366430316439343036
|
||||||
|
32353931393064666231323863656165363066313236613332356161363139616636333963386130
|
||||||
|
37363030383765613132353161613766633635363033656561343038633839313933646264383730
|
||||||
|
64336339646264383332373639326164373163383966626363653762643037353636376336626136
|
||||||
|
33346533303036326531316332306461646361376435316438376161663162336335353938366565
|
||||||
|
30633133653431393066393961313138383337313731653031323432633766356338316366373432
|
||||||
|
32373937663961623739633439636661336461346132376533373961666432353937373066643165
|
||||||
|
61663063363661633938373365393665356665636562646265313834373962336566393835633339
|
||||||
|
34396666396162613162326331313037303933366564623837386338363063636564656339336639
|
||||||
|
66346465366233663534373465313930323134313835316464363263383866313563396263616535
|
||||||
|
63383265623865636162346635613863356266336664343434393437656134353639353535383332
|
||||||
|
62623934643930313939646466663336633034343534396137333264623263663866663339663266
|
||||||
|
30343234356536663262616363376663646264353331646164376331376639363135373137396437
|
||||||
|
37363166386233356434656237373535326162303437346233623263663534383032363638376134
|
||||||
|
61653939306433393437656465343066613530396265396262373433383637656266303064623234
|
||||||
|
64333062353435373863636439663561393763333538303836303631666262326430623835656138
|
||||||
|
37653562353562373935333235316430613737653862303933333062643663333364333966643461
|
||||||
|
33323335346566363337643161303835356336306232653763346639323265373432376239363566
|
||||||
|
64373562653238333865326335613133636335373739396335633631313431363061616139303463
|
||||||
|
37333364393438666532396131343637373833353766396234383739306565646439366438653032
|
||||||
|
33656330343061636338643465653664326338663233316631303465666632653436633135643664
|
||||||
|
64616132366632666431653262393035393163343664303961396431666236303864303865343634
|
||||||
|
35616634613165373637653235323164323666343436646339646637646234306163333462393063
|
||||||
|
32346534636165656436353036316232303266616135303663343631303565623562616237306365
|
||||||
|
65303938646239393564333461343238636335336533633265383066653734613332656563666434
|
||||||
|
31316665613630336263613934316361383332363164323266373565323239343033666663396534
|
||||||
|
39323739313636616232663535386439363065333766623837336230303334656466656262613363
|
||||||
|
37386664336436376530373436353235616437333834646563353830626162336261333135383866
|
||||||
|
64383930316531373366646335306131633166353161336463376530353066356530393665393063
|
||||||
|
31613636386532623035373866373065633233633135343439616662616232366337313764646436
|
||||||
|
64626262643532613136373238316561616361393433323066326333663663353236393662396539
|
||||||
|
31653036303031303462643231333965653536666136313638613832393361666131363435633932
|
||||||
|
31663864326563663230626237643763333737613239373134626433636564386231383961316162
|
||||||
|
39383165336433626466393935383363396333636131643733663866356434366664613766396263
|
||||||
|
34313934626133653361633665323131613736306331373732323434323535346136393964356231
|
||||||
|
62346136356331393238346333393266613365633563626238353530333931613330663765393936
|
||||||
|
32333261353634646366323238353238643837633735636662356630373464343330626630656130
|
||||||
|
36356565356430643133386461313335343436316263303064366139316638663161356332386362
|
||||||
|
37376431393661386231313763303266313630323362363664336366633035353562303439373630
|
||||||
|
33343265633630343065363461363064653933303932613761303538393734373962613633386539
|
||||||
|
66636534333537313135356665633966326430373062346136326532666638303334653263646431
|
||||||
|
38393131653338316663313265653861663334326635353137623739396636333637343137636339
|
||||||
|
32303836373535326363396434326233623532633931653039643763326263616232333462616631
|
||||||
|
36666564623030396134346665386661386433366266363739626161653062323963313365353161
|
||||||
|
35643530343439326133613939353737653165326538666530366530323963363839373032326462
|
||||||
|
34666235376263616364656130633637346334353934396132353263313237316366303137386430
|
||||||
|
64653563333963313361303239666361336136356363306266633833366262326431616161613238
|
||||||
|
38653538613032386238623839663332613064333031303939363733396635373238666562386536
|
||||||
|
32316566666435376239386637396334643861643634316338613063656465373164646530363865
|
||||||
|
34373130636435326130633437303539646535336131393339613139383636333763336530636534
|
||||||
|
34636666666265373636326666333130623863316465663333653466353063313134386262333739
|
||||||
|
62626264393362353663303531313061643538663532333164336662343732373463623166396539
|
||||||
|
39396531376338616538633633343733343765306237656466666232623163303738643431633763
|
||||||
|
61656335616430653936303831393664653365363764333362373337323364323039363163353461
|
||||||
|
61336536316466396636306266353830316665343739613033346538333830306263386134613737
|
||||||
|
64316339613462346438656362346664303762643766373364343931626530626439336634666537
|
||||||
|
31633964386564663531343764326666666261643464353438353035333665363434646661646663
|
||||||
|
38636239373331623061343730376632393963303732393533396464633131633435373161303163
|
||||||
|
66383461343861326665623463636262336562633936623563373136613063356362383862663232
|
||||||
|
37333331373431393137363735613366656434323065346661366433663464666363343231393863
|
||||||
|
64633530316230653065356165366135396531663731323866376162306238343962376362633234
|
||||||
|
61626563306431623336623737353931316236623333623337383366613262346631646330313637
|
||||||
|
39366239396330303461303666396431663062626533336136643039353034633230353765353334
|
||||||
|
38613362653963336162326163356662356661386630353664333265373032316531656131376665
|
||||||
|
37376262363130336161613230333863653662623436666361396561613935323432663665643138
|
||||||
|
38616564636634613164313666393532396265396135326538336665373232316461326635306131
|
||||||
|
34343632636637653835653131613161316237346239363830386536363933643532333533373333
|
||||||
|
39643364306163666366376535653333323435383332633961343930633635383030356463333964
|
||||||
|
39626130666166313234386439383833616265316265363430343134633730336261383435356138
|
||||||
|
62373063346238613061363033343366623633373034346531303538396335653938646664303962
|
||||||
|
31336634623135616237323837623831306535316463613266326262663934303938373132343735
|
||||||
|
37656335333263326531646162393738653632376164323165393563656138613830633936396433
|
||||||
|
61353332343134636564333233393863643837353366386234376237623435663765343366363033
|
||||||
|
63326233383962633266303962613361643464613764303531333930363736323535386632393766
|
||||||
|
61353666303134663466333330383031333933666137346364656364313965656164303065303530
|
||||||
|
34616130653061613934393831373130333566363736626261316330303966656162326638333130
|
||||||
|
66373133613536623566303432356666346535636237616561323063643439616436393666376536
|
||||||
|
32613830343636393031333737376332396230313034393062663437613838363263333233613439
|
||||||
|
30623039336339373234326261306435366332656164613439376139346333616331326561383963
|
||||||
|
30643133376632656564616536323863373237623263366266396264633464373765316164346165
|
||||||
|
37636233633661643362636630356333333766613036663335613264333439323239633861363034
|
||||||
|
34663937376530653837653236303839336631313863363239626632646436653638366638366566
|
||||||
|
39306538353231623434373537313862386335393262633062313432646232623863383731313031
|
||||||
|
30656366363837366666393933346238363336363030373836386230343062363661306263633163
|
||||||
|
33626562623935643665626239386133636531393536336661613430343630333961303233343430
|
||||||
|
63656666346138643163393663316134666336323961626163376461663635633834333337393062
|
||||||
|
61656163613234633965356133666335343065626137633137333266613561633936386136643134
|
||||||
|
37383562663031393133326662623136386539633066323336306262346236613161613637626162
|
||||||
|
36636133666334333636653535623732343233396430653566393165353431303739656239373738
|
||||||
|
33323939633264303139323162613964306237376461383261646635343036313639626539373238
|
||||||
|
32336537373436373338386432646139303831383138326564333739353761616336346461356532
|
||||||
|
38303138656533386231303336336564656135346162376662663962663763353830663237323138
|
||||||
|
33373331656637363139626132393231313136303936633161636261643264313230356261366165
|
||||||
|
39666331306262643566663830626663656530303831343231323336306266363735393966613062
|
||||||
|
63353938386263376166316335656164633233633465303065663565373764343031663866653135
|
||||||
|
64663766386436653665356265333565323336636539656237303334383636353161643366656637
|
||||||
|
66356532373130323236313936623964663433333965326662333833316437326461326165376661
|
||||||
|
66396537653032346666363965313339323331303864616230646361386335663138613433326261
|
||||||
|
35613430363864336635343434333761656639633863323534653862383936653762646134356664
|
||||||
|
38326463326239636162333435656561343739366364313738663535636136323439373462643832
|
||||||
|
62633661663337343538393466613734633531666532353161616231323161646237653736346561
|
||||||
|
64323063656366373931396639393261643333393333626539663561636661393936316539633263
|
||||||
|
63343331313464623636353031343232613534663565303538333164306531303438616539386364
|
||||||
|
30376233333630336431336364663834633734636261353364343564333639623737363538313462
|
||||||
|
61616233663335303062336635376435643965373039336231346234363436356238356162613138
|
||||||
|
65326532663461616263626238346535623136633039613939353132313836373962646463333535
|
||||||
|
65313562346631633435616232366166373763346337303561326130333936346130363431383036
|
||||||
|
62356435616630396539303633343166646461393030336462366463636138316333633363643636
|
||||||
|
65376131333731356566333237363266656466376539326438313930376363386231616138336335
|
||||||
|
65333735653830373035656265336331346562353233663465343935383235303930633831613137
|
||||||
|
64303130666532303733633133386334613733383562613661643931636136386264396438316366
|
||||||
|
61653964643135646332343764666134336666336232376465353462356632346533633961636534
|
||||||
|
32643234396636303135663562656435376561336235303837643932366334616265383639343733
|
||||||
|
65633833653763643366646232343765306131313465326263623636386131376463356139623334
|
||||||
|
39343163366439643334646663393434353333316234623530393431643539346435616263303734
|
||||||
|
61633066653838363933646230623238653431393061646430383537343363643562653831336362
|
||||||
|
37626630633161653763386663373630306564663339393265663732623434643231326335376562
|
||||||
|
37663234643466366535326461396631633430613431346134316635653032663033623465346338
|
||||||
|
61353331393631343365663233376330333730366161353362626166646232313666336333386265
|
||||||
|
33373761313536326165343339346263316636363362393365663034353964373164643763383037
|
||||||
|
3666
|
118
vars/vars.yml
118
vars/vars.yml
@ -1,118 +0,0 @@
|
|||||||
$ANSIBLE_VAULT;1.1;AES256
|
|
||||||
62356266326334623764386265376638616664653061653834633862326162366136343036383037
|
|
||||||
3236326264353231306664343331313661383066653162640a643738303463613038616433363231
|
|
||||||
65333565313031303033633334313430613161343435376361363533626638306332343166383836
|
|
||||||
3565393839663162650a366236373831653637376361383536636333333136386639643735373762
|
|
||||||
39333039323066383035643438656665623866343161643064383039316166366230646565346166
|
|
||||||
30343834333636333962333236636130646263396536653030333563363963623930656633656162
|
|
||||||
31626633326530653731636262326532383565633261353964653535313232333334653939613561
|
|
||||||
38333361383862333562353534376434313163303438653236613062336531653266616238613239
|
|
||||||
64623637633366336561356265386161646534303338376533643439633435613434613138633132
|
|
||||||
64366638636363666365646234333264353633393835326464366261363938363232393962646462
|
|
||||||
64623535356333373865633464613334356164353263346638313732396431333331656238616338
|
|
||||||
65613631336631346230626338363330353764616332356266356630346361346631343333326339
|
|
||||||
65343837363637326232323566323263323733613864386230623438353739336534316633363333
|
|
||||||
61356466393735306539353135616566373065616664656437343435653131313830373934646433
|
|
||||||
63343662636661323934643536306638306137336633346635663337363361346161386632373164
|
|
||||||
34396639323566613136386462373466636463616162386266366230323231363839663662376231
|
|
||||||
66643133313939373338633563656134313035303161363462333337333838623430663162626539
|
|
||||||
36383735393733346631386132333132336430333031636537363936323033336630616462616564
|
|
||||||
32326561373737383833653033333463383561386462386563333733373633323065386239333830
|
|
||||||
34623435306336343264303165333432616530343564663639306135356632643664336263363439
|
|
||||||
66376634363637343165383536373263656631313461373630666235656261656437616662653566
|
|
||||||
64356664343861316437383236346165613262356534613364376537383962396665323964313064
|
|
||||||
61373337313234633362323266623666343835343335366166343538633061613063626364366637
|
|
||||||
61626435366337366533666333303165653361376239333732356535303362313430313962386366
|
|
||||||
64396631616139386134306565343233343238363866356364636130613337396366303234393564
|
|
||||||
31353536663039396365363163663463613265613264393733656134306237323239623238343536
|
|
||||||
31323430383464303032323031383665316466653530353934623136333335303764376661613736
|
|
||||||
66356533663631613634626266303430666236346363333564633330636666343338303733363263
|
|
||||||
65333232383138616631316365616431656531623161306430636265343336356161666561396664
|
|
||||||
30353832663863663764636366333836326163303164656464393661663237363038626162636131
|
|
||||||
35636533663733643533643963316137643435313434323864653335623263356665323761326435
|
|
||||||
65663462383161373462616637303436326537636338393739313331306666643866373966653566
|
|
||||||
31313961613832643931336666303865633137613438326433373966323130313936633265393363
|
|
||||||
33613663306430633138643235343662666562656534663434643131626430306463316433323364
|
|
||||||
63313539396663613537646631623935643538373263613235313838646661336633326464653861
|
|
||||||
61663566396437363864306235383931326535323434633238343031653465633162396439393730
|
|
||||||
32303635633139613538346430343936316166633331323036316333663833343733396232306164
|
|
||||||
62616132623538643531643635303130383162303732303566643935333066353737353538386238
|
|
||||||
65636465613661383234613963656238613863393337373165323737333936356533363462623632
|
|
||||||
62643934323262646436383261656463316464333930356136363335646561343364663762343563
|
|
||||||
64663037353862396265393762303861633435356432356564366234356263353731643035323737
|
|
||||||
31333634336362326535626533636533613138343561316139333766356661656138646666363365
|
|
||||||
61373462396633383436383964373365613333303934633839323334303036616237646465653535
|
|
||||||
31643330313164363266386136383464343134663439356531373039313966316366396265616232
|
|
||||||
61396435386237313932303166386361376537663333313038356664333637633930333135623034
|
|
||||||
61656361663662306439326333333133666235623462326334303130613963313962313364303837
|
|
||||||
62653934353331356232666430633763616135613831383762326131366336616436313530346365
|
|
||||||
31393063663263376132326234663439396262323836386563346135613632353231343734376333
|
|
||||||
37636333333632336436633363346232323837633461336537373138363265306538646337333535
|
|
||||||
35626538663731343565393132363035633438653966313136313035613061303133383962383764
|
|
||||||
61303962303862396331626437663338656632333063313435646666376430626235353861353264
|
|
||||||
34396362663130653766663563363665303064646133376235623837393965303435626337633637
|
|
||||||
62313364313061363235633636323639353338656232316266653435616635643937386162643133
|
|
||||||
62653838323962363534633839336136393830396237653561613463643430646137313262343563
|
|
||||||
37343631623334626138633830353634613036373531313439633335313137613965326339646164
|
|
||||||
61376662616265623364336264373330393738313938383864343034663365303836313465323733
|
|
||||||
35313535313333636439323834323231353431383034363732616635303638303938393437663565
|
|
||||||
36346235623634356636323835343032613563623230303734363865343763633363306238336139
|
|
||||||
37313065666466323533633764653964366665363831393062666437316235396266636134633566
|
|
||||||
39623837623239316132333232646263346362333433663661653036373233323261653439626165
|
|
||||||
64376639333836353236386337303333333565376436633166353266363237346162313466663430
|
|
||||||
62306433316531653539336665346237616431643765643161653063663431633339313939633435
|
|
||||||
64306634326533303035653633653862633738386131336431663434663637653830373537643066
|
|
||||||
36633232646362393932306162346436666162343463306666306130613239303438623066346265
|
|
||||||
32343034663539353665323734343561303965666331383337326537646434396233323563353134
|
|
||||||
61313232323333623966343339313066363335383532623061643331393938643765643939653035
|
|
||||||
38626133333939643262326561353635326461376633313861376139633462306665373133346364
|
|
||||||
33613766316534643138383637303839336162643762363334373061666436366634653536663364
|
|
||||||
33323437333964373339643334666632636631623666386432626135353362653931383736366339
|
|
||||||
37633861333234386534323062626130383136306161363631346465306366333633326366653765
|
|
||||||
64313737343565396439303261383165643136396165393733643833616366646432663566396562
|
|
||||||
63356331353961663335643732663532393233343066363331346538626135323662393839646163
|
|
||||||
32393062326564353531623563663361643563366164623739326131643935326336393061373039
|
|
||||||
34393164326438346163346365313366613261353963373631373863306236313236653637653265
|
|
||||||
64663837383134376439633536633238316565353132333038386563613433303231313163623639
|
|
||||||
39303338333731323031353462333162666565396134393234633562376563653163323163653537
|
|
||||||
38643561353537343939346430666634316166666465653935393738346463316464613164366264
|
|
||||||
37613662383937656664623335313539323638646164613030633164623036623330623365303537
|
|
||||||
61623164333736346463373765626238353035656261656439336437326264333839643463353130
|
|
||||||
63616139393661646462626164613332366338653735363634663531363461633961363566386561
|
|
||||||
31353262306631653931623837643662313065633162633630313735626138363861646434366433
|
|
||||||
64663839353438643335623762636266653033623966623162343631633530613166346262396564
|
|
||||||
35333263373763353165333737356235303465666561663633616665396334326135633666663162
|
|
||||||
66666631623635663437613961366337663061396266346333633135613735313461363130316332
|
|
||||||
35303761653535373838366532626434303731333466626465636330656238636638376235366638
|
|
||||||
61393365666262373364623364653265643334613835366439623938393831306664326437333230
|
|
||||||
63616265376663366433653664326232373062363763313064366665623031616633323838353864
|
|
||||||
38363562333163303163373933636336303031303062383864353661303832613438336130666661
|
|
||||||
61323631643338663331353530623064396361303266383534373034663564376664663133306637
|
|
||||||
37313561376532633163613037353862336532363163323137313630363762373938393164663837
|
|
||||||
65383163313837383466623330373031303531653961663164626535353939663836626431316166
|
|
||||||
61653964363566636161306535626661623239623965653632343936656633306637366330333536
|
|
||||||
66363064626466363831643837306635356238376530396164373263363437633562633063366534
|
|
||||||
36313535643836643362353134393430333532343337373161306534343538643964346262613663
|
|
||||||
37323530613331343264363230656538353233323139653764656266303663303461376139613165
|
|
||||||
66633936303632666264336562363263346233356533653062366531633637626335613639303133
|
|
||||||
38393931626538313231376336353839623233306564633034393938643263343061623461646333
|
|
||||||
33323831396639636661373831383532303330663131323237396430396530663235316130363430
|
|
||||||
39323430363533343236386633643938303565666236343639343730333266346238616164353165
|
|
||||||
30333266623866316361356538373138643638616335373436353439336662323437303137303462
|
|
||||||
65393963336463623230393565306130313335373361646232386631343333653339303934333331
|
|
||||||
30396632376639316634663262333965356131383938313864323530326332633039363865363833
|
|
||||||
65356630343039376231346561326537323035316639316563633065313833626635396463343366
|
|
||||||
62626338393262363539306131386362616330356364373734363666333864366166306633373165
|
|
||||||
34656135316230626633346431313033373736666235376166373062323437363963643265313832
|
|
||||||
65373262653230376539316163626538326432303536323166623738633764353362366662633166
|
|
||||||
30626463613264613065386361363065663165643938353961376363323239323663643232353332
|
|
||||||
37656134316637363139633938656263643366373461393561363731653237383935666136303366
|
|
||||||
66306638376130353238653563313133663933643431333835383961633538626365646165616232
|
|
||||||
33633663396337636365323835373166386536386231383632383038663037663265333966643737
|
|
||||||
34303233626337623062636139613231346363303235623362373634343865653538646663653731
|
|
||||||
37383937323739303431613237633437306531346438613235313934613361356533616465396533
|
|
||||||
38323430343831356562326239623137653366303738356239396161663762663738636139303134
|
|
||||||
32366638333335626539366530366563363538623865366665343037643239336238303030633733
|
|
||||||
61613461323837656463663630663630313162616133333632326432383635656631643663613464
|
|
||||||
65383863643435363437386435336166663261336561633231666536353537303461623837373162
|
|
||||||
62666234646137666663303336393732396365656138363536343032366338376331
|
|
Reference in New Issue
Block a user