Skip to content

Instantly share code, notes, and snippets.

@benhartwich
benhartwich / nginx.conf
Created July 12, 2023 05:59
AgenGPT nginx config
server {
listen 80;
listen [::]:80;
server_name xy.com;
return 301 https://$server_name$request_uri;
}
server {
listen 443 ssl;
listen [::]:443 ssl;
{% if not is_feed() %}
{# display web player for episode #}
{{ episode.player }}
{# display contributors if module is active #}
{% if shortcode_exists("podlove-episode-contributor-list") %}
<h3>Am Mikrofon:</h3>
{# see http://docs.podlove.org/podlove-publisher/reference/shortcodes.html#contributors for parameters #}
[podlove-episode-contributor-list]
@benhartwich
benhartwich / nginx.conf
Last active April 14, 2022 09:43
Nginx RMTP with HLS variants
user www-data;
worker_processes auto;
error_log /var/log/nginx/error.log notice;
pid /var/run/nginx.pid;
events {
worker_connections 1024;
use epoll;
@benhartwich
benhartwich / homeserver.yaml
Last active August 9, 2022 15:26
Matrix Synapse
# This file shows only my changes - please insert / adapt them at the right place at your file!
# SSL
tls_certificate_path: "/etc/matrix-synapse/fullchain.pem"
tls_private_key_path: "/etc/matrix-synapse/privkey.pem"
tls_dh_params_path: "/etc/matrix-synapse/dhparam.pem"
no_tls: false
# Chat
web_client: false
stages:
- deploy
deploy-master:
stage: deploy
environment: production
script:
- ssh [email protected] "
cd /var/www/wordpress/wp-content/themes/theme-name &&
git pull
@benhartwich
benhartwich / vhost.conf
Last active October 2, 2018 07:10
LimeSurvey nginx
server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
server_name xy.com;
access_log /var/log/nginx/access.log;
error_log /var/log/nginx/error.log;
ssl_certificate /etc/letsencrypt/live/xy.com/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/xy.com/privkey.pem;
add_header Strict-Transport-Security "max-age=63072000; includeSubdomains; preload";
root /var/kunden/lime/httpdocs;
@benhartwich
benhartwich / my.conf
Created May 9, 2018 10:59
MariaDB Tuning
[mysqld]
connect_timeout = 15
wait_timeout = 120
max_allowed_packet = 16M
sort_buffer_size = 16M
bulk_insert_buffer_size = 16M
tmp_table_size = 32M
max_heap_table_size = 32M
thread_handling = pool-of-threads
#thread_pool_size = 128
@benhartwich
benhartwich / vhost.conf
Created May 8, 2018 07:42
PHP FPM for nginx
[username]
listen = /var/run/php/php7.2-fpm-username.sock
listen.allowed_clients = 127.0.0.1
user = username
group = username
listen.mode = 0660
listen.owner = username
listen.group = www-data
@benhartwich
benhartwich / opendkim.sh
Created February 14, 2018 11:55
opendKIM autocreate new domain
#!/bin/bash
# Gib die Namen der OpenDKIM Config Dateien an
Key_Table="KeyTable"
Signing_Table="SigningTable"
Trusted_Hosts="TrustedHosts"
# Gib deine Mail Adresse an
MAIL="[email protected]"
@benhartwich
benhartwich / commands.conf
Created January 18, 2018 12:51
Icinga2 Centreon Commands Integration
object CheckCommand "centreon-snmp-load" {
import "plugin-check-command"
command = [ "/home/icinga2/centreon-plugins/centreon_plugins.pl"]
arguments = {
"--plugin" = "os::linux::snmp::plugin"
"--mode" = "load"
"--hostname" = "$address$"
"--snmp-version" = "2c"
"--snmp-community" = "$snmp_community$"