Skip to content

Instantly share code, notes, and snippets.

@maddes-b
maddes-b / virtual_network.md
Last active December 8, 2022 00:58
Virtual Network Interface Card (NIC) with systemd on Debian 9 "Stretch"

systemd.network allows to create virtual network interface cards in different ways. The common type is MACVLAN where the virtual NIC has its own MAC address, which allows to assign separate IP addresses via DHCP/RA.

  1. Switch away from old /etc/network stuff to systemd. If you have special manual settings then adapt them to systemd.network
systemctl enable systemd-networkd.service
systemctl disable networking.service
systemctl status networking.service systemd-networkd.service
systemctl start systemd-networkd.service
systemctl stop systemd-networkd.service
@maddes-b
maddes-b / fritzbox-cert-update.sh
Created January 12, 2020 14:32 — forked from wikrie/fritzbox-cert-update.sh
Fritzbox Fritz!Box AVM SSL Letsencrypt automatically update
#!/bin/bash
# parameters
USERNAME="maybe empty"
PASSWORD="fritzbox-password"
CERTPATH="path to cert eg /etc/letsencrypt/live/domain.tld/"
CERTPASSWORD="cert password if needed"
HOST=http://fritz.box
# make and secure a temporary file
@maddes-b
maddes-b / fritz_cert_upload.py
Created April 14, 2020 17:29 — forked from shtrom/fritz_cert_upload.py
Upload a TLS key and cert to a FRITZ!Box, in pretty Python
#!/usr/bin/env python
# vim: fileencoding=utf-8
"""
Upload a TLS key and cert to a FRITZ!Box, in pretty Python
Copyright (C) 2018 Olivier Mehani <shtrom@ssji.net>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.