Skip to content

Instantly share code, notes, and snippets.

@mastdiekin
mastdiekin / uninstall_python3.MD
Created March 7, 2021 10:42 — forked from zhensongren/uninstall_python3.MD
How to uninstall python3 from Ubuntu

To list all python versions in default locations

ls /usr/bin/python*

To remove just python3 package

sudo apt-get remove python3.5

plus it's dependent packages

sudo apt-get remove --auto-remove python3.5

plus configuration and/or data files of python3

sudo apt-get purge python3.5

@mastdiekin
mastdiekin / ssh_wsl.txt
Created February 27, 2021 16:13 — forked from jaimehrubiks/ssh_wsl.txt
Make SSH work in WSL [Windows subsystem for Linux] (Tested in Ubuntu Oct 2018)
# 1. Reinstall open ssh server
sudo apt-get purge openssh-server
sudo apt-get install openssh-server
# 2. Install public key
# vim .ssh/authorized_keys blabla
chmod 400 .ssh/authorized_keys
# 3. Edit open ssh server config files
# Some settings are not needed, but these will help for sure to make it work
@mastdiekin
mastdiekin / node_nginx_ssl.md
Created November 25, 2020 21:45 — forked from bradtraversy/node_nginx_ssl.md
Node app deploy with nginx & SSL

Node.js Deployment

Steps to deploy a Node.js app to DigitalOcean using PM2, NGINX as a reverse proxy and an SSL from LetsEncrypt

1. Sign up for Digital Ocean

If you use the referal link below, you get $10 free (1 or 2 months) https://m.do.co/c/5424d440c63a

2. Create a droplet and log in via ssh

I will be using the root user, but would suggest creating a new user

@mastdiekin
mastdiekin / m3u8-to-mp4.md
Created November 25, 2020 16:31 — forked from tzmartin/m3u8-to-mp4.md
m3u8 stream to mp4 using ffmpeg

1. Copy m3u8 link

Alt text

2. Run command

echo "Enter m3u8 link:";read link;echo "Enter output filename:";read filename;ffmpeg -i "$link" -bsf:a aac_adtstoasc -vcodec copy -c copy -crf 50 $filename.mp4