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/bash -xe | |
# see also https://gist.github.com/nickboldt/6afc71826e82518c5e7b7d3c3fdcc4f3 | |
# merge sse repos into a single repo | |
START_TIME=`date +%s` | |
# work in a tempdir. The tmp-dir name is something like /home/user/tmp/this_scripts_name/ | |
tmpdir=~/tmp/${0/.sh/.tmp} | |
tmpdirCache=~/tmp/${0/.sh/.tmp}_cache |
#!/usr/bin/python | |
import csv | |
import json | |
import requests | |
import configparser | |
""" | |
Usage: | |
Add the following to config.ini with appropriate values: |
client | |
dev tun | |
remote example.com | |
resolv-retry infinite | |
nobind | |
persist-key | |
persist-tun | |
ca [inline] | |
cert [inline] | |
key [inline] |
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
# | |
# Slightly tighter CORS config for nginx | |
# | |
# A modification of https://gist.github.com/1064640/ to include a white-list of URLs | |
# | |
# Despite the W3C guidance suggesting that a list of origins can be passed as part of | |
# Access-Control-Allow-Origin headers, several browsers (well, at least Firefox) | |
# don't seem to play nicely with this. | |
# |