From 5d769f55d7b720729a748b699ee305c51dd41a4c Mon Sep 17 00:00:00 2001 From: Marko Korhonen Date: Fri, 9 Apr 2021 21:02:47 +0300 Subject: [PATCH 01/14] Update dotdrop, add viirujateippi profile --- config.yaml | 3 +++ dotdrop | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/config.yaml b/config.yaml index c218624..484fa06 100644 --- a/config.yaml +++ b/config.yaml @@ -256,3 +256,6 @@ profiles: localhost: include: - terminal + ViiruJaTeippi: + include: + - terminal diff --git a/dotdrop b/dotdrop index 636c1ad..900f705 160000 --- a/dotdrop +++ b/dotdrop @@ -1 +1 @@ -Subproject commit 636c1ade26a5205ca84aef624ed971c0e529ffa7 +Subproject commit 900f705b30ee07063ecc7f2df24fc7b28a9451a5 From 8c6393a776ab303f021338acf0484d2079bb02ac Mon Sep 17 00:00:00 2001 From: Marko Korhonen Date: Sun, 11 Apr 2021 10:42:33 +0300 Subject: [PATCH 02/14] Update facebook video regex's --- home/.config/mimeo/associations.txt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/home/.config/mimeo/associations.txt b/home/.config/mimeo/associations.txt index 9d7fd9a..c15f426 100644 --- a/home/.config/mimeo/associations.txt +++ b/home/.config/mimeo/associations.txt @@ -17,7 +17,10 @@ mpvqueue %U ^https?://(?:[a-z0-9\-]+\.)+[a-z]{2,6}(?:/[^/#?]+)+\.(?:mp4|mkv|webm|avi|3gp|gif|gifv) mpvqueue %U - ^https?://www.facebook.com/.*/videos/ + ^https://www.facebook.com/watch/?v=.* + +mpvqueue %U + ^https://fb.watch/.* mpvqueue %U ^https?://gfycat.com/.* From 5a218b3925650d6918c8a2962928546a5ff22c7e Mon Sep 17 00:00:00 2001 From: Marko Korhonen Date: Mon, 19 Apr 2021 20:17:45 +0300 Subject: [PATCH 03/14] =?UTF-8?q?Rework=20tr=C3=A6fik=20config?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docker/{traefik => træfik}/docker-compose.yaml | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename docker/{traefik => træfik}/docker-compose.yaml (100%) diff --git a/docker/traefik/docker-compose.yaml b/docker/træfik/docker-compose.yaml similarity index 100% rename from docker/traefik/docker-compose.yaml rename to docker/træfik/docker-compose.yaml From 0c07155261c5f8ec8e82bfb286c82f0ac179f25a Mon Sep 17 00:00:00 2001 From: Marko Korhonen Date: Mon, 19 Apr 2021 20:19:14 +0300 Subject: [PATCH 04/14] Misc changes --- docker/træfik/docker-compose.yaml | 18 ++++++++-- docker/wordpress/docker-compose.yaml | 54 ---------------------------- 2 files changed, 15 insertions(+), 57 deletions(-) delete mode 100644 docker/wordpress/docker-compose.yaml diff --git a/docker/træfik/docker-compose.yaml b/docker/træfik/docker-compose.yaml index 0b89e1f..1a4f791 100644 --- a/docker/træfik/docker-compose.yaml +++ b/docker/træfik/docker-compose.yaml @@ -17,9 +17,10 @@ services: volumes: - /etc/localtime:/etc/localtime:ro - /var/run/docker.sock:/var/run/docker.sock:ro - - /docker/traefik/traefik.yml:/traefik.yml:ro - - /docker/traefik/dashboard-users:/dashboard-users:ro - - /docker/traefik/acme.json:/acme.json + - /docker/træfik/træfik/traefik.yml:/traefik.yml:ro + - /docker/træfik/træfik/dashboard-users:/dashboard-users:ro + - /docker/træfik/træfik/acme.json:/acme.json + - /docker/træfik/træfik/log:/var/log labels: - 'traefik.enable=true' @@ -36,6 +37,17 @@ services: - 'traefik.http.routers.dashboard.tls.certresolver=http' - 'traefik.http.routers.dashboard.service=api@internal' + fail2ban: + image: crazymax/fail2ban:latest + container_name: fail2ban + restart: unless-stopped + network_mode: "host" + cap_add: + - NET_ADMIN + - NET_RAW + volumes: + - /docker/træfik/træfik/log:/var/log/træfik:ro + - /docker/træfik/fail2ban:/data networks: proxy: external: true diff --git a/docker/wordpress/docker-compose.yaml b/docker/wordpress/docker-compose.yaml deleted file mode 100644 index 8db8cd1..0000000 --- a/docker/wordpress/docker-compose.yaml +++ /dev/null @@ -1,54 +0,0 @@ -version: "3.3" - -services: - wordpress: - container_name: wordpress - image: wordpress:latest - environment: - - TZ=Europe/Helsinki - - WORDPRESS_DB_HOST=mariadb-wordpress:3306 - - WORDPRESS_DB_USER=wordpress - - WORDPRESS_DB_PASSWORD=wordpress - - WORDPRESS_DB_NAME=wordpress - restart: unless-stopped - networks: - - proxy - - wordpress - volumes: - - /docker/wordpress/wordpress:/var/www/html - - /etc/localtime:/etc/localtime:ro - labels: - - "traefik.enable=true" - - - "traefik.http.routers.wordpress-redirect.entrypoints=http" - - "traefik.http.routers.wordpress-redirect.rule=Host(`johanna.korhonen.cc`)" - - "traefik.http.middlewares.http2https.redirectscheme.scheme=https" - - "traefik.http.routers.wordpress-redirect.middlewares=http2https" - - - "traefik.http.routers.wordpress.entrypoints=https" - - "traefik.http.routers.wordpress.rule=Host(`johanna.korhonen.cc`)" - - "traefik.http.routers.wordpress.tls=true" - - "traefik.http.routers.wordpress.tls.certresolver=http" - - "traefik.http.routers.wordpress.service=wordpress" - - "traefik.docker.network=proxy" - - "traefik.http.services.wordpress.loadbalancer.server.port=80" - - mariadb-wordpress: - image: mariadb - container_name: mariadb-wordpress - volumes: - - /docker/wordpress/mariadb:/var/lib/mysql - restart: always - networks: - - wordpress - environment: - - MYSQL_ROOT_PASSWORD=oT8Veu3Vre4ohj3E - - MYSQL_DATABASE=wordpress - - MYSQL_USER=wordpress - - MYSQL_PASSWORD=wordpress - -networks: - proxy: - external: true - wordpress: - external: false From 052041ac72caab4d5581974c6f74e6e07c549dab Mon Sep 17 00:00:00 2001 From: Marko Korhonen Date: Mon, 19 Apr 2021 20:19:41 +0300 Subject: [PATCH 05/14] Begin setting up openldap etc --- docker/auth/.gitignore | 1 + docker/auth/docker-compose.yaml | 20 +++++++++++++++++ docker/homeautomation/docker-compose.yml | 28 ------------------------ 3 files changed, 21 insertions(+), 28 deletions(-) create mode 100644 docker/auth/.gitignore create mode 100644 docker/auth/docker-compose.yaml diff --git a/docker/auth/.gitignore b/docker/auth/.gitignore new file mode 100644 index 0000000..4c49bd7 --- /dev/null +++ b/docker/auth/.gitignore @@ -0,0 +1 @@ +.env diff --git a/docker/auth/docker-compose.yaml b/docker/auth/docker-compose.yaml new file mode 100644 index 0000000..7bbc62f --- /dev/null +++ b/docker/auth/docker-compose.yaml @@ -0,0 +1,20 @@ +version: "2" + +services: + openldap: + container_name: openldap + image: osixia/openldap:stable + environment: + - TZ=Europe/Helsinki + - LDAP_ORGANIZATION="Korhonen" + - LDAP_DOMAIN="korhonen.cc" + - LDAP_ADMIN_PASSWORD="${LDAP_ADMIN_PASSWORD}" + hostname: ldap.korhonen.cc + ports: + - 389:389 + - 636:636 + restart: unless-stopped + volumes: + - /docker/auth/openldap/ldap:/var/lib/ldap + - /docker/auth/openldap/slapd.d:/etc/ldap/slapd.d + - /etc/localtime:/etc/localtime:ro diff --git a/docker/homeautomation/docker-compose.yml b/docker/homeautomation/docker-compose.yml index ebcf120..ea29011 100644 --- a/docker/homeautomation/docker-compose.yml +++ b/docker/homeautomation/docker-compose.yml @@ -64,37 +64,9 @@ services: restart: unless-stopped depends_on: - home-assistant - - opentts devices: - "/dev/snd:/dev/snd" - opentts: - image: synesthesiam/opentts - container_name: opentts - ports: - - 5500:5500 - command: --marytts-url http://marytts:59125 --mozillatts-url http://mozillatts:5002 - tty: true - networks: - - homeautomation - depends_on: - - marytts - - mozillatts - restart: unless-stopped - marytts: - image: synesthesiam/marytts:5.2 - container_name: marytts - restart: unless-stopped - tty: true - networks: - - homeautomation - mozillatts: - image: synesthesiam/mozilla-tts - container_name: mozillatts - tty: true - networks: - - homeautomation - node-red: container_name: node-red image: nodered/node-red From 2ca80f9f20e5b0a9cccc9183713ccc9c29c627b6 Mon Sep 17 00:00:00 2001 From: Marko Korhonen Date: Mon, 19 Apr 2021 20:20:21 +0300 Subject: [PATCH 06/14] Update dotdrop --- dotdrop | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dotdrop b/dotdrop index 900f705..9ae90d5 160000 --- a/dotdrop +++ b/dotdrop @@ -1 +1 @@ -Subproject commit 900f705b30ee07063ecc7f2df24fc7b28a9451a5 +Subproject commit 9ae90d51095b7fe9b26350c8dd33902e862466a5 From 966748c1e5fca488dc332f9ea35ce4dadf8f70cf Mon Sep 17 00:00:00 2001 From: Marko Korhonen Date: Mon, 19 Apr 2021 20:20:55 +0300 Subject: [PATCH 07/14] Update dotdrop --- dotdrop | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dotdrop b/dotdrop index 9ae90d5..900f705 160000 --- a/dotdrop +++ b/dotdrop @@ -1 +1 @@ -Subproject commit 9ae90d51095b7fe9b26350c8dd33902e862466a5 +Subproject commit 900f705b30ee07063ecc7f2df24fc7b28a9451a5 From 4f5835e88117f4e706b2e012303b63fa5032887a Mon Sep 17 00:00:00 2001 From: Marko Korhonen Date: Mon, 19 Apr 2021 20:21:19 +0300 Subject: [PATCH 08/14] Add viiru ja teippu ssh --- home/.ssh/config | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/home/.ssh/config b/home/.ssh/config index a00f477..b39bd8d 100644 --- a/home/.ssh/config +++ b/home/.ssh/config @@ -40,3 +40,8 @@ host takamaki HostName 10.200.200.5 port 22 user reekymarko + +host viirujateippi + HostName viirujateippi.fi + port 22 + user functionalhacker From 117f7fc56bb60b484cc1f5e30cfb9aa0ffa35547 Mon Sep 17 00:00:00 2001 From: Marko Korhonen Date: Mon, 19 Apr 2021 20:22:23 +0300 Subject: [PATCH 09/14] Update dotdrop --- dotdrop | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dotdrop b/dotdrop index 900f705..9ae90d5 160000 --- a/dotdrop +++ b/dotdrop @@ -1 +1 @@ -Subproject commit 900f705b30ee07063ecc7f2df24fc7b28a9451a5 +Subproject commit 9ae90d51095b7fe9b26350c8dd33902e862466a5 From 6d6ffef7cf2db2d57a50ec6035f6e77c16e48fd5 Mon Sep 17 00:00:00 2001 From: Marko Korhonen Date: Wed, 21 Apr 2021 17:15:30 +0300 Subject: [PATCH 10/14] Add dbus-update-activation-environment to sway exec, fixes pinentry-gnome3 --- home/.config/sway/conf.d/08-exec.conf | 1 + 1 file changed, 1 insertion(+) diff --git a/home/.config/sway/conf.d/08-exec.conf b/home/.config/sway/conf.d/08-exec.conf index 6791278..19289cf 100644 --- a/home/.config/sway/conf.d/08-exec.conf +++ b/home/.config/sway/conf.d/08-exec.conf @@ -15,6 +15,7 @@ exec { /usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1 mpDris2 swaymsg workspace 1 + dbus-update-activation-environment DISPLAY } exec_always { From edda8b944040daae2bf0d17f23c7c46ae8543549 Mon Sep 17 00:00:00 2001 From: Marko Korhonen Date: Wed, 21 Apr 2021 17:46:54 +0300 Subject: [PATCH 11/14] Fix gpg-agent --- home/.config/zsh/01-env.zsh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/home/.config/zsh/01-env.zsh b/home/.config/zsh/01-env.zsh index e742dd4..2658b0d 100644 --- a/home/.config/zsh/01-env.zsh +++ b/home/.config/zsh/01-env.zsh @@ -39,7 +39,7 @@ export AUR_PAGER=$PAGER export GPG_TTY="$(tty)" # set SSH_AUTH_SOCK if not logging in over SSH -if [ "$SSH_CONNECTION" != "" ]; then +if [ "$SSH_CONNECTION" -eq "" ]; then export SSH_AUTH_SOCK=$(gpgconf --list-dirs agent-ssh-socket) gpgconf --launch gpg-agent fi From bf2f8630cd01d5da5d662cc209aff2daa57afd25 Mon Sep 17 00:00:00 2001 From: Marko Korhonen Date: Thu, 22 Apr 2021 18:00:22 +0300 Subject: [PATCH 12/14] Enable optimized build for rust and x86-v3 --- home/.config/pacman/makepkg.conf | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/home/.config/pacman/makepkg.conf b/home/.config/pacman/makepkg.conf index 48b6c3f..2153de5 100644 --- a/home/.config/pacman/makepkg.conf +++ b/home/.config/pacman/makepkg.conf @@ -15,8 +15,9 @@ CARCH="x86_64" CHOST="x86_64-pc-linux-gnu" CPPFLAGS="-D_FORTIFY_SOURCE=2" -CFLAGS="-march=x86-64 -mtune=generic -O2 -pipe -fstack-protector-strong -fno-plt" -CXXFLAGS="-march=x86-64 -mtune=generic -O2 -pipe -fstack-protector-strong -fno-plt" +CFLAGS="-march=native -mtune=generic -O2 -pipe -fstack-protector-strong -fno-plt" +CXXFLAGS="${CFLAGS}" +RUSTFLAGS="-C opt-level=3 -C target-cpu=native" LDFLAGS="-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now" MAKEFLAGS="-j$(nproc)" DEBUG_CFLAGS="-g -fvar-tracking-assignments" From 2db8a37ee271c1c75f16627b327553a7ae826f07 Mon Sep 17 00:00:00 2001 From: Marko Korhonen Date: Thu, 22 Apr 2021 18:35:03 +0300 Subject: [PATCH 13/14] Add packager information to makepkg --- home/.config/pacman/makepkg.conf | 1 + 1 file changed, 1 insertion(+) diff --git a/home/.config/pacman/makepkg.conf b/home/.config/pacman/makepkg.conf index 2153de5..0e01401 100644 --- a/home/.config/pacman/makepkg.conf +++ b/home/.config/pacman/makepkg.conf @@ -1,3 +1,4 @@ +PACKAGER="Marko Korhonen " DLAGENTS=('file::/usr/bin/curl -gqC - -o %o %u' 'ftp::/usr/bin/curl -gqfC - --ftp-pasv --retry 3 --retry-delay 3 -o %o %u' 'http::/usr/bin/curl -gqb "" -fLC - --retry 3 --retry-delay 3 -o %o %u' From 8b147866bf9cfe97cd859edcbd05d7bab43cef49 Mon Sep 17 00:00:00 2001 From: Marko Korhonen Date: Sat, 8 May 2021 12:06:36 +0300 Subject: [PATCH 14/14] Update dotdrop --- dotdrop | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dotdrop b/dotdrop index 9ae90d5..5d4b12e 160000 --- a/dotdrop +++ b/dotdrop @@ -1 +1 @@ -Subproject commit 9ae90d51095b7fe9b26350c8dd33902e862466a5 +Subproject commit 5d4b12eaf44b940ba3a478ded48b1cde039471a6