JFFS script to isolate configured guest wifi networks on AsusWRT Merlin into a seperate VLAN.
Original script from: http://www.snbforums.com/threads/ac56u-how-to-add-bridges-with-dhcp-servers.20326/#post-189032
| # Modified from: | |
| # http://findingscience.com/ruby/ssl/2013/01/13/reading-an-ssl-cert-in-ruby.html | |
| require "socket" | |
| require "openssl" | |
| host = "www.piranhas.co" | |
| tcp_client = TCPSocket.new("www.piranhas.co", 443) | |
| ssl_client = OpenSSL::SSL::SSLSocket.new(tcp_client) |
| # 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 3 of the License, or | |
| # (at your option) any later version. | |
| # | |
| # This program is distributed in the hope that it will be useful, | |
| # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
| # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
| # GNU General Public License for more details. | |
| # |
JFFS script to isolate configured guest wifi networks on AsusWRT Merlin into a seperate VLAN.
Original script from: http://www.snbforums.com/threads/ac56u-how-to-add-bridges-with-dhcp-servers.20326/#post-189032
| #! /bin/sh | |
| ### BEGIN INIT INFO | |
| # Provides: pumacontrol | |
| # Required-Start: $remote_fs $syslog | |
| # Required-Stop: $remote_fs $syslog | |
| # Default-Start: 2 3 4 5 | |
| # Default-Stop: 0 1 6 | |
| # Short-Description: Puma web server |
| import socket | |
| from BaseHTTPServer import HTTPServer | |
| from SimpleHTTPServer import SimpleHTTPRequestHandler | |
| class MyHandler(SimpleHTTPRequestHandler): | |
| def do_GET(self): | |
| if self.path == '/ip': | |
| self.send_response(200) | |
| self.send_header('Content-type', 'text/html') | |
| self.end_headers() |
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000| #!/bin/sh | |
| # ########################################################## # | |
| # wrapper for mosh to work with ssh's proxycommand directive # | |
| # this only makes sense if the machine is directly reachable # | |
| # from the internet using udp. # | |
| # ########################################################## # | |
| THISSCRIPT="`basename \"$0\"`" | |
| REMOTE="$1" |
Locate the section for your github remote in the .git/config file. It looks like this:
[remote "origin"]
fetch = +refs/heads/*:refs/remotes/origin/*
url = [email protected]:joyent/node.git
Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/* to this section. Obviously, change the github url to match your project's URL. It ends up looking like this: