Skip to content

Instantly share code, notes, and snippets.

View federicociro's full-sized avatar

Federico B federicociro

  • Sanofi
View GitHub Profile
@Postrediori
Postrediori / Linux-RocketLake-UHD-750.md
Last active June 17, 2023 13:18
Setup UHD 750 GPU on Intel Rocket Lake processors on Linux

Description

Linux distros don't support newest (May 2021) Rocket Lake GPUs by default. Tested on:

  • Fedora 34
  • Ubuntu 20.04.2.0
  • Ubuntu 21.04

Even if i915 module is loaded (lsmod | grep i915), the graphics is still running in software mode. This issue can be checked in the following ways:

@deg0nz
deg0nz / iOS-VPN-autoconnect-WireGuard.mobileconfig
Created January 23, 2021 22:18
Connect iOS to WireGuard VPN when connected to untrusted WiFi
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>PayloadContent</key>
<array>
<!-- Connect to VPN when connected to untrusted networks -->
<dict>
@FrankWu100
FrankWu100 / fancontrol-gpio.service
Last active April 29, 2022 18:37
GPIO Fan-Control daemon
[Unit]
Description=fancontrol-gpio
[Service]
Type=simple
ExecStart=/usr/bin/fancontrol-gpio
[Install]
WantedBy=multi-user.target
@cota
cota / gpg.sh
Created December 1, 2019 23:10
export/import a GPG key
# Export a specific `foo@bar.com` key in an encrypted (i.e. password-protected) file `mykey.sec.asc`
gpg --armor --export-secret-keys foo@bar.com | gpg --armor --symmetric --output mykey.sec.asc
# Import the key in `mykey.sec.asc`. `gpg` will ask for the password used when exporting.
gpg --no-use-agent --output - mykey.sec.asc | gpg --import
@alexbosworth
alexbosworth / inotify-channel-backup.md
Last active March 29, 2024 01:33
Backup channel.backup file using systemd and inotify

LND backup script for channel.backup using inotify

Install inotify

sudo apt install inotify-tools

Create script to watch for changes and copy on change

@brentjanderson
brentjanderson / Howto.md
Created February 20, 2018 17:55
SSH Tunneling with Firefox

Sometimes it is useful to route traffic through a different machine for testing or development. At work, we have a VPN to a remote facility that we haven't bothered to fix for routing, so the only way to access a certain machine over that VPN is via an SSH tunnel to a machine that is reachable over the VPN. Other times, I have used this technique to test internet-facing requests against sites I am developing. It is pretty easy, and if you don't use firefox regularly, you can treat Firefox as your "Proxy" browser and other browsers can use a normal configuration (Although you can also configure an entire system to use the proxy, other articles exists that discuss this potential).

  1. Open a terminal
@jgrodziski
jgrodziski / docker-aliases.sh
Last active June 19, 2024 07:01
Useful Docker Aliases
############################################################################
# #
# ------- Useful Docker Aliases -------- #
# #
# # Installation : #
# copy/paste these lines into your .bashrc or .zshrc file or just #
# type the following in your current shell to try it out: #
# wget -O - https://gist.githubusercontent.com/jgrodziski/9ed4a17709baad10dbcd4530b60dfcbb/raw/d84ef1741c59e7ab07fb055a70df1830584c6c18/docker-aliases.sh | bash
# #
# # Usage: #
@alopresto
alopresto / gpg_git_signing.md
Last active January 18, 2024 22:42
Steps to enable GPG signing of git commits.

If anyone is interested in setting up their system to automatically (or manually) sign their git commits with their GPG key, here are the steps:

  1. Generate and add your key to GitHub
  2. $ git config --global commit.gpgsign true ([OPTIONAL] every commit will now be signed)
  3. $ git config --global user.signingkey ABCDEF01 (where ABCDEF01 is the fingerprint of the key to use)
  4. $ git config --global alias.logs "log --show-signature" (now available as $ git logs)
  5. $ git config --global alias.cis "commit -S" (optional if global signing is false)
  6. $ echo "Some content" >> example.txt
  7. $ git add example.txt
  8. $ git cis -m "This commit is signed by a GPG key." (regular commit will work if global signing is enabled)