l mors.r: add autotether
This commit is contained in:
parent
37e2e08a0a
commit
c337e2593b
@ -41,6 +41,7 @@ with import <stockholm/lib>;
|
||||
<stockholm/lass/2configs/ppp/umts-stick.nix>
|
||||
# <stockholm/lass/2configs/remote-builder/morpheus.nix>
|
||||
# <stockholm/lass/2configs/remote-builder/prism.nix>
|
||||
<stockholm/lass/2configs/autotether.nix>
|
||||
{
|
||||
krebs.iptables.tables.filter.INPUT.rules = [
|
||||
#risk of rain
|
||||
|
16
lass/2configs/autotether.nix
Normal file
16
lass/2configs/autotether.nix
Normal file
@ -0,0 +1,16 @@
|
||||
{ config, lib, pkgs, ... }:
|
||||
{
|
||||
systemd.services.usb_tether = {
|
||||
script = ''
|
||||
${pkgs.android-tools}/bin/adb -s QV770FAMEK wait-for-device
|
||||
${pkgs.android-tools}/bin/adb -s QV770FAMEK shell svc usb setFunctions rndis
|
||||
'';
|
||||
};
|
||||
services.udev.extraRules = ''
|
||||
ACTION=="add", SUBSYSTEM=="usb", ENV{PRODUCT}=="fce/320d/510", TAG+="systemd", ENV{SYSTEMD_WANTS}="usb_tether.service"
|
||||
'';
|
||||
systemd.network.networks.android = {
|
||||
matchConfig.Name = "enp0s20u1";
|
||||
DHCP = "yes";
|
||||
};
|
||||
}
|
Loading…
Reference in New Issue
Block a user