Skip to content

Instantly share code, notes, and snippets.

@adil1214
Created June 9, 2019 13:23
Show Gist options
  • Save adil1214/74104745c11b4ddb995bfc0b1c2b3dcd to your computer and use it in GitHub Desktop.
Save adil1214/74104745c11b4ddb995bfc0b1c2b3dcd to your computer and use it in GitHub Desktop.

Revisions

  1. adil1214 created this gist Jun 9, 2019.
    13 changes: 13 additions & 0 deletions crontab.sh
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,13 @@
    #crontab
    # disable/enable wireles interface (@wifi-iface)/(client)

    # this is to disable (at 21:10 everyday)
    10 21 * * * uci set wireless.@wifi-iface[3].disabled='1' ; wifi
    # and this to enable (...)
    13 21 * * * uci delete wireless.@wifi-iface[3].disabled ; wifi
    # =================================
    # disable/enable ap (...)
    10 21 * * * uci set wireless.@wifi-iface[1].disabled='1'; wifi
    13 21 * * * uci set wireless.@wifi-iface[1].disabled='0'; wifi

    # careful; if you enable 2+ ifaces at the same time = problems