Skip to content

Instantly share code, notes, and snippets.

View luckylittle's full-sized avatar
:octocat:
Working for @RedHatOfficial

Lucian Maly luckylittle

:octocat:
Working for @RedHatOfficial
View GitHub Profile
@luckylittle
luckylittle / gnome_keyring_remove_pswd.zsh
Created August 2, 2023 02:38
REMOVE Annoying popup for Chrome/Chromium asking for GNOME Keyring password
#!/bin/zsh
source venv/bin/activate
python -c 'import keyring;keyring.set_password("system","username","");'
python -c 'import keyring;keyring.get_password("system","username");'
deactivate
@luckylittle
luckylittle / timezones.sh
Last active July 27, 2023 05:45
Quick & Easy way to display various timezones within your shell
#!/bin/bash
echo "----------------------------"
echo "Local Time"
date
echo "----------------------------"
echo ""
echo "Time in Los Angeles, CA"
export TZ=America/Los_Angeles
date
echo ""
@luckylittle
luckylittle / README.md
Created June 29, 2023 09:16
Python transformation of Openshift's ImageContentSourcePolicy. It changes the mirrors based on the source. Useful for cases when you do not need to mirror images, but you just proxy them.

Example of the ImageContentSourcePolicy:

spec:
  repositoryDigestMirrors:
  - mirrors: artifactory-proxy.domain.com.au/redhat-registry-openshift-remote/redhat-openshift-logging-kibana6-rhel8
    source: registry.redhat.io/openshift-logging/kibana6-rhel8
  - mirrors: artifactory-proxy.domain.com.au/redhat-registry-openshift-remote/redhat-openshift-gitops-1-gitops-operator-bundle
 source: registry.connect.redhat.io/openshift-gitops-1/gitops-operator-bundle
@luckylittle
luckylittle / 01-Create and Manage Cloud Resources.md
Last active October 29, 2024 07:39
Professional Google Cloud Architect (2023) -- Cohort ID: PCA02-GETCERT/2023.05.25

Create and Manage Cloud Resources

Creating virtual machine

  • To attach a persistent disk to a virtual machine instance, both resources must be in the same zone
  • If you want to assign a static IP address to an instance, the instance must be in the same region as the static IP

GCloud CLI

@luckylittle
luckylittle / dl_links.csv
Last active March 3, 2026 15:19
Manning Publications Ebooks Downloader
@luckylittle
luckylittle / wayland_brightness.sh
Created May 1, 2023 06:19
Change the brightness of your monitor programatically
#!/bin/zsh
# Turn the monitor brightness down to almost zero
dconf write /org/gnome/shell/extensions/soft-brightness/current-brightness 0.01
# Turn the monitor brightness up to usable value
dconf write /org/gnome/shell/extensions/soft-brightness/current-brightness 0.8
@luckylittle
luckylittle / generate_pdf.sh
Created April 19, 2023 06:08
Beautiful PDF generator out of Markdown powered by podman
#!/bin/zsh
########################################
########################################
## ##
## Author: lmaly@redhat.com ##
## Takes Markdown file `in.md` and ##
## converts it into a LaTeX PDF !! ##
## ##
########################################
@luckylittle
luckylittle / fedora_upgrade.sh
Last active October 7, 2023 16:42
Typical workflow of Fedora system-wide upgrade to the next releasever
#!/usr/bin/env bash
sudo dnf upgrade --refresh
sudo dnf install dnf-plugin-system-upgrade
sudo dnf system-upgrade download --releasever=37
sudo dnf system-upgrade reboot
sudo dnf install remove-retired-packages
remove-retired-packages
sudo dnf repoquery --unsatisfied
sudo dnf repoquery --duplicates