Skip to content

Instantly share code, notes, and snippets.

View gfrancesco's full-sized avatar

gfrancesco

View GitHub Profile
eix-sync
emerge -uDNa --with-bdeps=y world
emerge -a --depclean
revdep-rebuild
## RVM
$ rvm get stable
$ rvm list known
# emerge --sync
# eselect news read new
# emerge portage
# emerge eix
# eix-update
# screen -R eme
# emerge -uDNa --with-bdeps=y world
# nano /etc/conf.d/hostname
@gfrancesco
gfrancesco / gentoo-sshd-conf
Last active January 12, 2021 20:13
SSH server conf for gentoo web server. Apply to other distros too. Be sure to understand all options before using.
# user modified sshd_config
#### Networking options ####
# Listen on a non-standard port > 1024
#Port 50000
# Restrict to IPv4. inet = IPv4, inet6 = IPv6, any = both
AddressFamily inet
# Listen only on the internal network address
# emerge --sync
# eselect profile set 1
# eselect news read new
# USE="-perl nginx_modules_http_gzip_static -nginx_modules_http_geo -X -alsa -cups -ant -vim" >> /etc/make.conf
# MAKEOPTS="-j1" >> /etc/make.conf
# emerge portage
# emerge eix
# eix-update
# emerge app-misc/screen
@gfrancesco
gfrancesco / brew routine
Last active May 19, 2016 12:42
brew upgrade and maintenance
brew update
brew outdated
brew upgrade
brew cleanup -n
brew cleanup

Keybase proof

I hereby claim:

  • I am gfrancesco on github.
  • I am gfrancesco (https://keybase.io/gfrancesco) on keybase.
  • I have a public key whose fingerprint is 790C BF82 044E 584C DA27 7F72 9BFD C4B0 3E11 B882

To claim this, I am signing this object:

- Download on phone Magisk.zip and twrp-fajita-XXXX.img
- Update from official system update
- enable usb debugging from options
- reboot into bootloader
- fastboot boot twrp-fajita-XXXX.img
- from twrp 'Advanced -> Install Recovery Ramdisk' and select twrp-fajita-XXXX.img
- from twrp install Magisk.zip
- wipe cache
- reboot
@gfrancesco
gfrancesco / cf_mikrotik_dns.txt
Last active October 28, 2024 17:34
Mikrotik v6.44+ script to update Cloudflare DNS
# Get the following:
# - cfZoneId : 'Zone ID' on the right column of your domain page
# - dnsName : e.g. 'my_subdomain.example.com'
# - cfToken : on CF upper right corner 'My Profile' -> 'API Tokens' -> 'Create Token'
#
# then get the cfDnsId with this API call, replace the variables with your values:
# curl -X GET "https://api.cloudflare.com/client/v4/zones/$cfZoneId/dns_records?type=A&name=$dnsName" \
# -H "Authorization: Bearer $cfToken"
#
# Required permissions for the script AND the scheduler: read, write, policy, test