Skip to content

Instantly share code, notes, and snippets.

View plembo's full-sized avatar

Phil Lembo plembo

View GitHub Profile
@plembo
plembo / reverttowsl1.md
Last active March 9, 2025 21:50
Revert to WSL 1

Revert to WSL 1 from WSL 2

I'll spare everyone the rant. This gist will be an all business how to revert to WSL (Windows Subsystem for Linux) on Windows 10 from version 2 back to version 1.

Note that enabling Hyper-V destabilized the (highly managed) system my company provides me. This is probably unique to the image used for the machine and the updates that base has received. So I'm not surprised by the issues people are having with Hyper-V and the Virtual Machine Platform.

My personal Windows virtual machines remain on WSL 1 because I just don't have the energy to deal with all the drama when I've already put in a full shift at work.

@plembo
plembo / gngpgupdatefiles.md
Last active March 13, 2021 16:41
Updating gnupg keychain from gpg to kbx

Bringing gnupg up to date: from gpg to kbx

GNU Privacy Guard made a change to its keystore with version 2.1 in 2014, including removal of the separate private keystore. The main difference users may notice is that the public keyring is now called "pubring.kbx" instead of "pubring.gpg". Its new keybox format is supposed to improve performance.

After continuing to use the old format through several upgrades, I finally decided to bring my evironment up to date.

The steps are in the GNUPg doc:

@plembo
plembo / secprintwindt.md
Last active July 8, 2022 06:36
Secure printing for Windows Desktop

Secure printing for Windows Desktop

See Secure Printing on Ubuntu Desktop for the backstory and theory. Here, I'm going to just briefly describe the steps to install a networked IPPS printer on Windows 10.

Printer has a local DNS name of "printer1.example.com". You can substitute the IP address of the printer, but note you may have SSL certificate issues. Insecure IPP can be used as a fallback, in which case the URI would be "http://xxx.xxx.xxx.xxx:631".

Before beginning, be sure to install the printer vendor's basic driver package (you won't need all their fancy utiltiies to use native Windows printing).

@plembo
plembo / nmbrnetkvm.md
Last active April 4, 2025 16:38
NetworkManager bridged network for KVM guests

Setting up a bridged network for KVM guests

This will work with either networkd or NetworkManager as a resolver. In fact, this is the only way to do bridged KVM (libvirtd) networking with NetworkManager.

If you're using NetworkManager (on a desktop or laptop, for example) on your KVM host, follow these instructions to set up a bridge interface.

Once you have the host bridge set up, proceed as follows:

  1. Create a bridge network device inside KVM. Edit and save the below text as file host-bridge.xml:
@plembo
plembo / googledriveappslist.md
Last active March 3, 2021 20:39
List of Google Drive Apps

List of Google Drive Apps

These are the apps I use with Google Drive. Not listed are app connections that get installed when an extension or desktop app is originally set up.

@plembo
plembo / chromeappsinstall.md
Last active December 29, 2024 03:04
Installing Chrome and Progressive Web Apps

Chrome and Progressive Web Apps Installation Notes

Google Chrome and Chromium-based browsers (like Vivaldi, Brave, and Microsoft Edge) support Progressive Web Apps (PWAs) on all platforms. The menu options differ slightly between browsers, but the concepts behind them are the same. Vivaldi's controls for this differ significantly from those in Chrome, Brave, and Edge. I have no idea why. Check out Vivaldi's help pages for details.

PWAs

Desktop menu items and desktop shorcuts are created in Chrome when a PWA is installed using the special "install" icon over on the right end of the address bar. An "installed" PWA opens as a new browser window sans tool and address bars. One advantage of PWAs over shortcuts is that PWA's can configure desktop notifications (most mail client PWAs do this: e.g., Gmail, Outlook and Proton Mail -- some others include Google Drive, YouTu

@plembo
plembo / favfonts.md
Last active January 4, 2022 15:09
Favorite Fonts

Favorite Fonts

UI

Linux UI

Noto regular or Ubuntu Regular.

Windows UI

Just learn to live with the defaults. Not a hill worth dying on.

Terminals and Editors

All platforms:

@plembo
plembo / addbr0ubunmcli.md
Last active April 21, 2025 08:05
Add br0 to Ubuntu desktop using nmcli

Add a bridge interface to Ubuntu desktop using nmcli

Had to do this for some advanced networking with KVM, and couldn't figure out how to do it using the Nework Manager gui. Did find an article later that showed how to do it with nmtui, but it's so much easier to record what you did when using the cli.

In the examples below "eth0" is the name of my physical interface. By default on Ubuntu and most distributions that will almost certainly be different, for example: "eno1", "ens1", or "enp2s0".

To see what everything looks like before starting:

@plembo
plembo / isgroupcreationdisabled.md
Last active February 12, 2021 23:43
Has Microsoft 365 group creation been disabled

Is Microsoft 365 group creation disabled?

Stumbled on this in a corporate test environment when I tried to create a new Microsoft Team (an operation that requires rights to create new groups) and was only given the choice of adopting an existing group.

By default Microsoft 365 expects everyone is able to create groups on the tenant. Microsoft recommends that you not change that. Then they go ahead and tell you how to change it anyway.

"Manage who can create Microsoft 365 Groups." Microsoft Docs, https://docs.microsoft.com/en-us/microsoft-365/solutions/manage-creation-of-groups?view=o365-worldwide. Retrieved February 12, 2021.

Well, by now this little bit of dangerous knowledge has made its rounds, and perhaps that's why you wound up here.

So the question is, how do you tell if its been done in your tenant?

@plembo
plembo / usevirtclone.md
Last active August 29, 2022 14:52
Using virt-clone

Using virt-clone

The virt-clone utility is a useful tool for rapidly reproducing KVM (libvirtd) virtual machines.

Basic command to clone an existing virtual machine:

$ sudo virt-clone \
--original debian1 \
--name debian2 \
--file /var/lib/libvirt/images/debian2.qcow2