Skip to content

Instantly share code, notes, and snippets.

@bmaupin
bmaupin / free-database-hosting.md
Last active May 7, 2024 20:03
Free database hosting
@hackerb9
hackerb9 / bwtest.sh
Last active May 7, 2024 20:02
Busybox compatible simple speedtest that downloads a file to /dev/null. Useful for sshing into various routers and seeing where the bottleneck is.
#!/bin/sh
# Silly speed test just by downloading a file directly to /dev/null
# Useful on routers which only have busybox installed.
# ↄ⃝🄯 B9 2016, 2018, 2023. Creative Commons Zero.
# NOTA BENE: cachefly has worked for over a decade, however they may
# be getting tired of scripts like this. Starting February 2023, their
# 100mb.test file is empty and the 50mb.test file holds 100MB.
dotest() {
@steven-tey
steven-tey / youtube-channel.tsx
Last active May 7, 2024 20:00
YoutubeChannel RSC
import { BlurImage, YouTube } from "@dub/ui";
import { nFormatter } from "@dub/utils";
import { Eye, UserCheck, Video } from "lucide-react";
import { Suspense } from "react";
export function YoutubeChannel({ id }: { id: string }) {
return (
<Suspense fallback={<div className="not-prose grid gap-4"></div>}>
<YoutubeChannelRSC id={id} />
</Suspense>
@thiamsantos
thiamsantos / db-conventions.md
Last active May 7, 2024 19:59
Convenções de nomenclatura para banco de dados

Convenções de nomenclatura para banco de dados

Geral

Os nomes das tabelas e colunas devem estar minúsculas e as palavras devem ser separadas por underscore, seguindo o padrão snake case. E todos os termos devem estar em inglês, exceto alguns termos que não há tradução apropriada para o inglês. Sempre prefira nomes descritivos, evitando ao máximo contrações.

Tabelas

Os nomes das tabelas devem estar no plural.

@suhas316380
suhas316380 / gist:969620d95e111b9b34c7e1689ada722d
Last active May 7, 2024 19:57
awscli and kubectl cheatsheet for EKS

check EKS release

curl -s https://docs.aws.amazon.com/eks/latest/userguide/doc-history.rss | grep "<title>Kubernetes version"

Create EKS Cluster

eksctl create cluster --version=1.14 --name suhas-eks-test --region us-east-1 --zones us-east-1a,us-east-1b --node-type t2.medium --nodes 2 --ssh-access=true --ssh-public-key basarkod-test

Without any nodeGroup - Public

eksctl create cluster --without-nodegroup --version=1.14 --name delete-me --vpc-public-subnets=subnet-123,subnet-456

Without any nodeGroup - PRIVATE

@Klerith
Klerith / Dockerfile
Last active May 7, 2024 19:56
Preparar imagen de Docker - Node App
# Install dependencies only when needed
FROM node:18-alpine3.15 AS deps
# Check https://github.com/nodejs/docker-node/tree/b4117f9333da4138b03a546ec926ef50a31506c3#nodealpine to understand why libc6-compat might be needed.
RUN apk add --no-cache libc6-compat
WORKDIR /app
COPY package.json yarn.lock ./
RUN yarn install --frozen-lockfile
@bswck
bswck / im_done.md
Last active May 7, 2024 20:04
100% is not enough

Acing a recruitment task? Get ready to be rejected!

I'm done, guys. In April, I sent an application for a Fullstack Python Developer internship at Samsung R&D.
After (allegedly) reviewing my CV, they decided to invite me to a test assessing my technical skills:

invitation to test

Great! I indeed got the e-mail with the invitation link soon after: test link

@lantz
lantz / gist:5640610
Last active May 7, 2024 19:55
Script to set up NAT with Mininet
#!/usr/bin/python
"""
Example to create a Mininet topology and connect it to the internet via NAT
through eth0 on the host.
Glen Gibb, February 2011
(slight modifications by BL, 5/13)
"""
@m-jovanovic
m-jovanovic / .editorconfig
Created June 7, 2023 12:17
Sample editor config with a bunch of rules turned off 😅
root = true
# C# files
[*.cs]
#### Core EditorConfig Options ####
# Indentation and spacing
indent_size = 4
indent_style = space