apt install nginx
apt install libnginx-mod-rtmp
apt install ffmpeg
apt install stunnel4
vim /etc/nginx/nginx.conf
- Remove http {} and mail {}
<?php | |
//скрыть, если не пользуетесь прокси. | |
$proxy="127.0.0.1:1337"; | |
$ch = curl_init(); | |
curl_setopt($ch, CURLOPT_PROXY, $proxy); | |
curl_setopt($ch, CURLOPT_PROXYTYPE, CURLPROXY_SOCKS5); |
apt install nginx
apt install libnginx-mod-rtmp
apt install ffmpeg
apt install stunnel4
vim /etc/nginx/nginx.conf
I want to disable monitor mode for the interal wlan0 card of the pi. If you want to do that too and use wlan1 as mon0 do:
sed -i 's/phy0/phy1/g' /usr/bin/pwnlib
If you want wlan0 and wlan1 in monitor mode and want to use wlan1 as pwnagotchi device, use this ps did didn't work for me but above example
sudo su
rm /etc/network/interfaces.d/wlan1-cfg
import warnings | |
from skimage.measure import compare_ssim | |
from skimage.transform import resize | |
from scipy.stats import wasserstein_distance | |
from scipy.misc import imsave | |
from scipy.ndimage import imread | |
import numpy as np | |
import cv2 | |
## |
class PromiseSimple { | |
constructor(executionFunction) { | |
this.promiseChain = []; | |
this.handleError = () => {}; | |
this.onResolve = this.onResolve.bind(this); | |
this.onReject = this.onReject.bind(this); | |
executionFunction(this.onResolve, this.onReject); | |
} |
Free O'Reilly books and convenient script to just download them.
Thanks /u/FallenAege/ and /u/ShPavel/ from this Reddit post
How to use:
download.sh
file and put it into a directory where you want the files to be saved.cd
into the directory and make sure that it has executable permissions (chmod +x download.sh
should do it)./download.sh
and wee there it goes. Also if you do not want all the files, just simply comment the ones you do not want.People experimenting with kubernetes clusters on the GKE not necessarily have money to keep a full cluster on at all time. GKE clusters can be easily resized, but this still incurs in the full instance cost when the cluster is up.
Google has added preemptible instances that are ideal for many
# Single line of Ruby <3. | |
ruby -rjson -ryaml -e "puts YAML.load_file('my_file.yml').to_json" | |
# You can also pipe it to Python to get pretty ouput | |
ruby -rjson -ryaml -e "puts YAML.load_file('my_file.yml').to_json" | \ | |
python -mjson.tool | |
# Thats all. :) |
# save it as /etc/profile.d/ssh-telegram.sh | |
# use jq to parse JSON from ipinfo.io | |
# get jq from here http://stedolan.github.io/jq/ | |
USERID="<target_user_id>" | |
KEY="<bot_private_key>" | |
TIMEOUT="10" | |
URL="https://api.telegram.org/bot$KEY/sendMessage" | |
DATE_EXEC="$(date "+%d %b %Y %H:%M")" | |
TMPFILE='/tmp/ipinfo-$DATE_EXEC.txt' | |
if [ -n "$SSH_CLIENT" ]; then |
smtp mail sending in cPython blocks the GIL. | |
This code is tested on python 2.7.8 and I'm using it with web2py | |
If you use Google Apps for your domain email and if you have admin access, you can easily use the gmail api. | |
Because you have admin access, you can create a "service account" in the Google Developer Console. | |
This makes authentication easy. | |
There are other authorisation methods when you don't have admin access, but they require interaction from the user via a browser. | |
To use this, you need to install these modules (From PyPI): | |
pyOpenSSL |