vim /etc/systemd/system/traefik.service
systemctl daemon-reload
useradd -r -s /bin/false -U -M traefik
mkdir -pv /etc/traefik/storage
mkdir -pv /var/log/traefik/
chown -Rfv traefik:traefik /etc/traefik/ /var/log/traefik/
# vim: set filetype=apache ts=2 sw=2 expandtab: | |
<IfModule mod_remoteip.c> | |
RemoteIPHeader X-Forwarded-For | |
RemoteIPTrustedProxy 127.0.0.1 | |
</IfModule> | |
<IfModule mod_setenvif.c> | |
SetEnvIfNoCase X-Forwarded-Proto "^https$" HTTPS=on | |
</IfModule> |
vim /etc/systemd/system/traefik.service
systemctl daemon-reload
useradd -r -s /bin/false -U -M traefik
mkdir -pv /etc/traefik/storage
mkdir -pv /var/log/traefik/
chown -Rfv traefik:traefik /etc/traefik/ /var/log/traefik/
#!/usr/bin/env sh | |
# @file /lib/systemd/system-sleep/touchpad | |
# @see https://askubuntu.com/questions/671910/touchpad-not-working-after-suspending-laptop | |
set -eu | |
# constants ---------------------------------------------------------- | |
MODULES="i2c_hid_acpi" |
#!/usr/bin/env ruby | |
# frozen_string_literal: true | |
class SrtFix | |
autoload(:Pathname, 'pathname') | |
def initialize(filepath) | |
@filepath = Pathname.new(filepath) | |
end |
-- ~/.config/mpv/scripts/icy-notify.lua | |
local utils = require 'mp.utils' | |
local msg = require 'mp.msg' | |
local DEBUG = false | |
-- table ---------------------------------------------------------------------- | |
table.union = function(a, b) | |
local result = {} |
#!/usr/bin/env ruby | |
# -*- coding: utf-8 -*- | |
autoload(:YAML, 'yaml') | |
autoload(:Pathname, 'pathname') | |
autoload(:Etc, 'etc') | |
# Sample of use: | |
# | |
# ```sh |
#!/usr/bin/env sh | |
# Some (useful) shell tricks. | |
set -eux | |
# read from deb file without extracting to the filesystem | |
dpkg --fsys-tarfile gitkraken.deb | tar xOf - ./usr/share/gitkraken/version > VERSION |
With
systemd 197
we have added native support for a number of different naming policies intosystemd
/udevd
proper and made a scheme similar tobiosdevname
's (but generally more powerful, and closer to kernel-internal device identification schemes) the default. The following different naming schemes for network interfaces are now supported byudev
natively:
- Names incorporating Firmware/BIOS provided index numbers for on-board devices (example:
eno1
)- Names incorporating Firmware/BIOS provided PCI Express hotplug slot index numbers (example:
ens1
)- Names incorporating physical/geographical location of the connector of the hardware (example:
enp2s0
)
import sys, os | |
reload(sys) | |
sys.setdefaultencoding("UTF-8") | |
# @see http://pythonic.zoomquiet.top/data/20130407004931/index.html |