Skip to content

Instantly share code, notes, and snippets.

View thimslugga's full-sized avatar
:octocat:

Adam Kaminski thimslugga

:octocat:
View GitHub Profile

Perfetto for upstream kernel development

Perfetto is super useful for understanding interactions between the kernel and applications. Outside of Android and ChromeOS, though it's use isn't as common. This doc tries to provide a basic walk through to get started using perfetto for upstream kernel development with classic linux distros, potentially running under qemu.

Install perfetto

Grab the latest linux- tarball: https://github.com/google/perfetto/releases

Often the tests I’m tracing need to run as root, so because of this, I copied the binaries in the tarball to /usr/local/bin/ and chmod +x the binaries to make

@thimslugga
thimslugga / cloudwatch-network-dashboard.yml
Last active November 25, 2025 14:53
CloudWatch Dashboards
AWSTemplateFormatVersion: '2010-09-09'
Description: 'CloudWatch Dashboard for Transit Gateway and Direct Connect resources monitoring'
Parameters:
DashboardName:
Type: String
Description: 'Name of CloudWatch Dashboard'
Default: 'NetworkDashboard'
# CloudFormation AllowedPattern only works with String types
@thimslugga
thimslugga / README.md
Last active November 17, 2025 15:17
Ansible Comprehensive Guide

Ansible Comprehensive Guide

Project Structure

.
├── ansible.cfg
├── hosts.yml
├── site.yml
├── roles/

Running Windows 10/11 Guest with GPU Passthrough using laptop running Fedora

Abstract

This is a full guide for people who wanted to set up Windows 10/11 VM with QEMU/KVM hypervisor enhancements for a laptop that is configured with hybrid graphics card like Intel/AMD + NVIDIA. This process will take about 1 to 2 hours, depending on your system's performance and your patience =)

There is another comprehensive guide you can follow here (shoutout to asus-linux team who made supergfxctl which is a very important tool for this guide). It is more up-to-date than mine. I would probably incorporate those information into my guide, but you are welcome to use this one as a reference!

Before we proceed:

  • This guide is exclusively for Fedora users because this distro is quite different to set up than other distro such as Arch. I would say Arch is easier to setup than Fedora, but sometimes you like to use Fedora than Arc
@thimslugga
thimslugga / alpine-from-scratch.md
Last active November 16, 2025 14:41 — forked from seia-soto/howto.md
How to compile lxc/incus on AlpineLinux

Download the miniroot tarball from the Alpine website and then add it to a Docker image:

FROM scratch

ENV ALPINE_ARCH x86_64
ENV ALPINE_VERSION 3.9.1

ADD alpine-minirootfs-${ALPINE_VERSION}-${ALPINE_ARCH}.tar.gz /
CMD ["/bin/sh"]
@thimslugga
thimslugga / IAM Permissions List.md
Created November 15, 2025 00:33 — forked from itshella-dom/IAM Permissions List.md
A list of IAM permissions you can use in policy documents. Collected from the myriad of places Amazon hides them. (incomplete)

List of IAM Permissions

  • aws:CurrentTime —To check for date/time conditions.
  • aws:EpochTime —To check for date/time conditions using a date in epoch or UNIX time.
  • aws:TokenIssueTime This is the date and time that temporary security credentials were issued and can be used with date/time conditions. (Note: This key is only available in requests that are signed using temporary security credentials. For more information about temporary security credentials, see Temporary Security Credentials.)
  • aws:principaltype —To check the type of principal (user, account, federated user, - etc.) for the current request.
  • aws:SecureTransport —To check whether the request was sent using SSL. For services - that use only SSL, such as Amazon RDS and Amazon Route 53, the aws:SecureTransport - key has no meaning.
  • aws:SourceArn —To check the source of the request, using the Am
@thimslugga
thimslugga / kcpasswordEncode.sh
Created November 10, 2025 15:43 — forked from brunerd/kcpasswordEncode.sh
Encode a string for use in macOS /etc/kcpassword using shell, printf, sed, awk and xxd
#!/bin/bash
#kcpasswordEncode (20220610) Copyright (c) 2021 Joel Bruner (https://github.com/brunerd)
#Licensed under the MIT License
#given a string creates data for /etc/kcpassword
function kcpasswordEncode () (
#ascii string
thisString="${1}"
@thimslugga
thimslugga / get-al2023-rpm.sh
Last active November 10, 2025 20:38
Download individual RPM package files from AL2023 repositories
#!/bin/bash
set -e
# Script to download individual RPM files from Amazon Linux 2023 repositories
#
# sudo yum install -y sqlite
#
# Usage: ./download-al2023-rpm.sh <package-name>
# Globals
@thimslugga
thimslugga / wikimd.html
Last active October 30, 2025 21:18
Simple wiki that renders markdown notes
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>WikiMD</title>
<script src="https://cdn.jsdelivr.net/npm/[email protected]/marked.min.js"></script>
<style>
* {