This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cover: | |
- platform: template | |
covers: | |
garage_gate: | |
device_class: garage | |
friendly_name: "Garage Gate" | |
value_template: | | |
{% if is_state('binary_sensor.garage_gate', 'off') %} | |
closed | |
{% else %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Jeg fant på https://forum.openwrt.org/t/help-getting-iptv-working-with-the-altibox-isp/38063/24?page=2 litt informasjon som jeg har skrevet om litt etter informasjon fra @trrunde (diskusjon.no). | |
The requirements for forwarding Altbox IPTV and Internet between fiber (with SFP or media converter) and a shared lan with both STBs and Internet clients are simple: | |
* tag VLAN 101 (IPTV) and 102 (Internet) on wan | |
* clone mac address of ISP gateway/router on the wan.101 interface | |
* run DHCP client on both wan.101 and wan.102 | |
* SNAT/masquerade between lan and both wan interfaces | |
* igmpproxy between wan.101 (upstream) and lan (downstream) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
execve("/home/portfolio/perlbrew/perls/perl-5.34.1/bin/perl", ["perl", "t/stat.t"], 0x7ffdd9beab48 /* 48 vars */) = 0 | |
brk(NULL) = 0x563492d8d000 | |
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory) | |
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fd57eb6b000 | |
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory) | |
openat(AT_FDCWD, "/home/portfolio/perlbrew/perls/perl-5.34.1/lib/5.34.1/x86_64-linux-thread-multi/CORE/tls/haswell/avx512_1/x86_64/libperl.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) | |
stat("/home/portfolio/perlbrew/perls/perl-5.34.1/lib/5.34.1/x86_64-linux-thread-multi/CORE/tls/haswell/avx512_1/x86_64", 0x7ffe2d377500) = -1 ENOENT (No such file or directory) | |
openat(AT_FDCWD, "/home/portfolio/perlbrew/perls/perl-5.34.1/lib/5.34.1/x86_64-linux-thread-multi/CORE/tls/haswell/avx512_1/libperl.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) | |
stat("/home/portfolio |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Only supported on Ubuntu 18.04 and newer | |
{% if grains.osmajorrelease >= 18 %} | |
userns.uidmap: | |
file.touch: | |
- name: /etc/subuid | |
- unless: test -f /etc/subuid | |
userns.gidmap: | |
file.touch: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
use strict; | |
use warnings; | |
use Chipcard::PCSC; | |
use Data::Dumper qw(Dumper); | |
use HTTP::Tiny (); | |
my $http = HTTP::Tiny->new(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# File /config/network/my-network in hassos-boot partition | |
[connection] | |
id=my-network | |
# Must be unique | |
uuid=YOUR_UUID_NUMBER | |
type=802-11-wireless | |
[802-11-wireless] | |
mode=infrastructure | |
ssid=YOUR_WIFI_NAME |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
:ubuntu-autoinstall | |
echo Starting Ubuntu ${ubuntu-version} ${archl} autoinstaller for ${initiator-iqn} | |
sanhook ${base-iscsi}:${hostname}.boot.ubuntu || sleep 1 | |
#sanhook ${base-iscsi}:${hostname}.boot.ubuntu && set ubuntu-cc-iscsi storage: { layout: { name: lvm }, config: [{type: disk, path: ${base-iscsi}:${hostname}.boot.ubuntu }] } || sleep 1 | |
#sanhook ${base-iscsi}:${hostname}.boot.ubuntu && set ubuntu-iscsi ISCSI_INITIATOR=${initiator-iqn} ISCSI_TARGET_NAME=${base-iqn}:${hostname}.boot.ubuntu ISCSI_TARGET_IP=${iscsi-server} ISCSI_TARGET_PORT=3260 || sleep 1 | |
# https://medium.com/@tlhakhan/ubuntu-server-20-04-autoinstall-2e5f772b655a | |
# https://ubuntu.com/server/docs/install/autoinstall | |
# https://github.com/canonical/cloud-init/blob/master/doc/examples/kernel-cmdline.txt | |
# https://matt.olan.me/raspberry-pi-iscsi-root-on-ubuntu-20-04/ | |
# https://askubuntu.com/questions/1235723/automated-20-04-server-installation-using-pxe-and-live-server-image |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sensor: | |
- platform: mqtt | |
state_topic: "sensor/server-room/temperature" | |
name: "Server room temperature" | |
unit_of_measurement: "°C" | |
value_template: "{{ value | round(1) }}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
make_vbox() { | |
pushd "$HOME/src/forked/ipxe/src" >/dev/null && | |
make CONFIG=vbox bin/intel--virtio-net--pcnet32.isarom && #EMBED=config/vbox/embedded.ipxe && | |
echo "Max size of VirtualBox ROM is 56KB, 57344 bytes" && | |
ls -l bin/intel--virtio-net--pcnet32.isarom && | |
prefix=$(date +%Y%m%d-%H%M%S) && | |
mkdir -p /ipxe/$prefix && | |
cp -v bin/intel--virtio-net--pcnet32.isarom /ipxe/$prefix/ && | |
echo -e "@echo off\r\nvboxmanage setextradata global VBoxInternal/Devices/pcbios/0/Config/LanBootRom C:\\Programs\\iPXE\\$prefix\\intel--virtio-net--pcnet32.isarom\r\nvboxmanage getextradata global enumerate\r\n" >/ipxe/setvboxrom.bat && | |
popd >/dev/null |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# server - make a device available remotely | |
apt install linux-tools-common linux-tools-generic hwdata | |
modprobe usbip-core | |
modprobe usbip-host | |
usbipd -D # (runs in background) | |
usbip list -l | |
usbip bind -b <busid> | |
# client - attach to remote device | |
apt install linux-tools-common linux-tools-generic-hwe-18.04 hwdata |
NewerOlder