Back up your computer. On the command line, in your home directory, create a directory for global installations:
mkdir ~/.npm-global
Configure npm to use the new directory path:
npm config set prefix '~/.npm-global'
| from pyrogram import Client | |
| import time | |
| from telethon.sync import TelegramClient, events | |
| api_id = 123465 | |
| api_hash = "0123456789abcdef0123456789abcdef" | |
| bot_token = "12345:0123456789abcdef0123456789abcdef" | |
| file = "test.bin" # generate with $ truncate -s 1500M test.bin | |
| username = "onetimeusername" # username to send test files. |
| What you will need: Server behind NAT (Server A), Server with static ip e.g. VPS for hosting Wireguard (Server B). | |
| 1) On your server B paste this commands in terminal: curl -O https://raw.githubusercontent.com/angristan/wireguard-install/master/wireguard-install.sh && chmod +x wireguard-install.sh && ./wireguard-install.sh | |
| 2) Create new client and save his ip. Mine will be 10.66.66.123 | |
| 3) Download this config to server A and connect to your server B with wireguard. | |
| 4) Depending on your client ip which we configured in step 2 type this commands in server B terminal (this time I wanted my Minecraft server exposed, so I chose 25565 port, yours can depends): | |
| sudo iptables -P FORWARD DROP | |
| sudo iptables -A FORWARD -i wg0 -o eth0 -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT | |
| sudo iptables -A FORWARD -i eth0 -o wg0 -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT |
Back up your computer. On the command line, in your home directory, create a directory for global installations:
mkdir ~/.npm-global
Configure npm to use the new directory path:
npm config set prefix '~/.npm-global'
Paste this link into your browser and hit "Enter": ms-windows-store://pdp/?ProductId=9n4wgh0z6vhq
| from .. import loader, utils # pylint: disable=relative-beyond-top-level | |
| import logging | |
| import requests | |
| logger = logging.getLogger(__name__) | |
| def register(cb): | |
| cb(WWTrMod()) |
| version=3.10.2 | |
| sudo apt-get install build-essential checkinstall libreadline-gplv2-dev libncursesw5-dev libssl-dev libsqlite3-dev tk-dev libgdbm-dev libc6-dev libbz2-dev | |
| wget https://www.python.org/ftp/python/$version/Python-$version.tgz | |
| tar -xvf Python-$version.tgz | |
| cd Python-$version | |
| ./configure | |
| make | |
| sudo checkinstall |