Skip to content

Instantly share code, notes, and snippets.

View nowak-ninja's full-sized avatar
🏡
Working from home

Sebastian Nowak nowak-ninja

🏡
Working from home
View GitHub Profile
@brianjbayer
brianjbayer / gist-mac-docker-desktop-multi-platform-images.md
Created December 5, 2023 00:40
How to enable and build multi-platform images in Docker Desktop for Mac

Enabling and Building Multi-Platform Images in Docker Desktop for Mac

🏫 To learn what multi-platform images are, see this post from Docker Multi-arch build and images, the simple way

You can use Docker Desktop for Mac to build and push multi-platform images to support your containers running on different CPU architectures like Intel/amd64 and Apple Silicon/arm64.

@ChristophShyper
ChristophShyper / wsl2-docker.md
Last active January 10, 2023 20:36
Instruction how to set up WSL2 to work with Docker in Windows 10

On Windows 10 build 18917 or higher

Win / Enable WSL and VMP

PowerShell:

Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux
Enable-WindowsOptionalFeature -Online -FeatureName VirtualMachinePlatform

Win / Set WSL 2 as default

@devnoname120
devnoname120 / My macOS setup.md
Last active October 28, 2025 12:23
My macOS setup

ℹ️ Enable iCloud end-to-end encryption:

  • Nobody knows that, but iCloud actually supports end-to-end encryption (see “Advanced Data Protection for iCloud”) but it’s disabled by default. If you care about data privacy, you should turn it on.
    • System settingsApple IDiCloud → Set Advanced Data Protection to On.
    • System settingsApple IDiCloud → Disable Access iCloud Data on the Web.
  • It supports almost all the native Apple apps, with the notable exceptions of iCloud Mail, Contacts, and Calendars. See official data protection matrix for more info.

Table of Contents

@mauler
mauler / http_server_auth.py
Last active September 6, 2025 11:46 — forked from fxsjy/SimpleAuthServer.py
Python3 http.server supporting basic HTTP Auth (username/password)
# Extended python -m http.serve with --username and --password parameters for
# basic auth, based on https://gist.github.com/fxsjy/5465353
from functools import partial
from http.server import SimpleHTTPRequestHandler, test
import base64
import os
class AuthHTTPRequestHandler(SimpleHTTPRequestHandler):
@jmassardo
jmassardo / Invoke-WebRequest_Ignore_SSL.ps1
Created February 26, 2019 15:19
PowerShell hack to ignore ssl certificates when using Invoke-WebRequest
add-type @"
using System.Net;
using System.Security.Cryptography.X509Certificates;
public class TrustAllCertsPolicy : ICertificatePolicy {
public bool CheckValidationResult(
ServicePoint srvPoint, X509Certificate certificate,
WebRequest request, int certificateProblem) {
return true;
}
}
@marcelkornblum
marcelkornblum / bulk-transfer-repos.py
Last active March 10, 2024 16:14
Simple Python script to rip everything from BitBucket across to Github with minimal interaction
# heavily inspired by https://gist.github.com/rbellamy/3c5033ba605a090824e8
# gets everything from bitbucket and brings it across to GH, adding LFS where necessary for file size
# then archives everything brought over
#
# runs on Python 3; does clone --mirror and push --mirror, cleaning up after itself
#
# you need git-lfs installed on the local system
# also make sure you've got git credential caching set up https://help.github.com/articles/caching-your-github-password-in-git/
import json
@levi-turner
levi-turner / RegisterNode.ps1
Last active December 9, 2021 11:54
Register a Qlik Node using Qlik CLI
<#
Run on the Central
#>
# Connect to Qlik Sense
# See https://github.com/ahaydon/Qlik-Cli/wiki/Establishing-a-connection for more connection options
Connect-Qlik
# Add the Node to the Cluster; store the password element of the response for the ZIP as $password
# nodePurpose: 0 (Production) / 1 (Development) / 2 (Both)
# engineEnabled, proxyEnabled, schedulerEnabled, $printingEnabled, $failoverCandidate as options
$password = New-QlikNode -hostname qlikserver2.domain.local -name qlikserver2 -nodePurpose 0 -engineEnabled -proxyEnabled
@andreafalzetti
andreafalzetti / create-url-parameter.sh
Created June 14, 2018 13:47
Creates a URL parameter in AWS SSM
#!/usr/bin/env bash
set -eu -o pipefail
# Usage:
# ./create-url-parameter /dev/projectName/API_BASE_URL https://api.example.com
name="$1"
value="$2"
description="$3"
@jalaziz
jalaziz / 70-ec2-nvme-devices.rules
Last active October 31, 2025 20:57
AWS EBS NVMe udev rules
# Copyright (C) 2006-2016 Amazon.com, Inc. or its affiliates.
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License").
# You may not use this file except in compliance with the License.
# A copy of the License is located at
#
# http://aws.amazon.com/apache2.0/
#
# or in the "license" file accompanying this file. This file is
@inkblot
inkblot / better-amazon-ecs-agent-task-roles.md
Last active January 20, 2024 22:17
ECS Task Roles - A Better Way

ECS Task Roles

ECS task roles are a great security feature that are hard to set up.

The Orthodoxy

The Amazon ECS documentation on setting up task roles tells you to do some questionable things. Among other things, it tells you to run the ECS agent with host networking (a security risk), use an iptables rule to cut off traffic from bridged containers to the host metadata (brittle), and set up additional iptables rules and sysctl settings to route 169.254.170.2:80 to the ECS agent on 127.0.0.1:51679 (brittle again).

Some Observations