Skip to content

Instantly share code, notes, and snippets.

@mattetti
mattetti / newWindowsMachine.sh
Last active April 20, 2024 11:21
bash script to run from WSL to setup Windows and Linux from the linux side. To run: `wget https://gist.githubusercontent.com/mattetti/9807e2a1e654a7c00bb9c13f340fc39f/raw/ -O newMachineSetup.sh` and then `bash newMachineSetup.sh`
#!/bin/bash
export WINHOME=$(wslpath "$(wslvar USERPROFILE)")
# github username is needed to pull down the dot files
export GITHUBUSERNAME="mattetti"
# wininstall does an install using winget and checks that it went well
function wininstall {
echo "Installing $1";
cmd.exe /C winget.exe install -e $1;

FWIW: I (@rondy) am not the creator of the content shared here, which is an excerpt from Edmond Lau's book. I simply copied and pasted it from another location and saved it as a personal note, before it gained popularity on news.ycombinator.com. Unfortunately, I cannot recall the exact origin of the original source, nor was I able to find the author's name, so I am can't provide the appropriate credits.


Effective Engineer - Notes

What's an Effective Engineer?

Более удобной и актуальной версией является эта статья с использованием traefik

https://gist.github.com/dancheskus/365e9bc49a73908302af19882a86ce52


Certbot и nginx, как обратный прокси в Docker (пример с 2 react проектами)

В результате будет 2 react проекта на 1 сервере доступных по разным ссылкам

@karlhillx
karlhillx / macos_big_sur_homebrew_apache_php_mariadb_2020.md
Last active April 20, 2024 11:15
macOS Big Sur 11.0 Setup: Homebrew + Apache + PHP + MariaDB (Regularly updated)

macOS Big Sur 11.0 Setup: Homebrew + Apache + PHP + MariaDB

This document helps get your macOS development environment up and running with the latest versions of Homebrew, Apache, PHP, and MariaDB.

@jakubmatyszewski
jakubmatyszewski / druid-opa-okta.md
Last active April 20, 2024 11:11
Druid auth with Okta & OPA

Druid auth with Okta & OPA

The goal is to enable Druid okta authentication with OPA (Open Policy Agent) authorization.
Basic auth is used for services to be able to talk with Druid using simple basic authorized requests. Keep in mind that even for basic authenticator, the authorizer is OPA. If OPA doesn't authorize basic druid users, cluster behaviour will fail.

Load extensions

@martinwoodward
martinwoodward / mermaid.md
Created February 11, 2022 20:34
GitHub HTML Rendering Pipeline
```mermaid
sequenceDiagram
    participant dotcom
    participant iframe
    participant viewscreen
    dotcom->>iframe: loads html w/ iframe url
    iframe->>viewscreen: request template
    viewscreen->>iframe: html & javascript
 iframe->>dotcom: iframe ready
@ooltcloud
ooltcloud / SyncTimeNtp.ps1
Created December 5, 2018 10:50
Powershell と NTP を使用した簡易時刻同期 (udp の ntp プロトコル使用)
#--------------
# NTP 時刻合わせ (NTP UDP:123)
#--------------
# NTP 積算秒数の起点時刻 (JST)
$ntpEpoch = New-Object System.Datetime @(1900, 1, 1, 9, 0, 0)
# Big Endian の符号なし Int32 を取得
Function getUInt32BE($bytes, $startIndex) {