This file contains hidden or 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
#!/bin/bash | |
sudo ip addr add 10.11.99.1/32 dev lo | |
ssh rmk true | |
ssh -O forward -L 10.11.99.1:8080:10.11.99.1:80 rmk | |
gnome-open http://10.11.99.1 | |
sudo socat TCP-LISTEN:80,reuseaddr,fork,su=nobody TCP:10.11.99.1:8080 |
This file contains hidden or 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
""" | |
Custom LOGIN_REQUIRED middleware which allows OAuth URLs. | |
""" | |
import utilities.middleware | |
from django.conf import settings | |
class CustomLoginRequiredMiddleware(utilities.middleware.LoginRequiredMiddleware): | |
def __call__(self, request): |
This file contains hidden or 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/python3 -u | |
import asyncio | |
import sh | |
from systemd import journal | |
from systemd.daemon import notify | |
GATEWAY_IP = "192.168.10.1" |
This file contains hidden or 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/env python | |
# -*- coding: utf-8 -*- | |
# | |
# Author: http://github.com/leoluk | |
# License: GPLv3 | |
# | |
""" | |
This quick-and-dirty script notifies you once a long-running shell command finishes, | |
using NotifyMyAndroid.com. |
NewerOlder