Skip to content

Instantly share code, notes, and snippets.

View gmolveau's full-sized avatar

Grégoire MOLVEAU gmolveau

View GitHub Profile
@gmolveau
gmolveau / cv_resume_explaining_roles_experiences.md
Last active February 20, 2024 07:53
CV/Resume - explaining your tech experiences
View cv_resume_explaining_roles_experiences.md

Different kind of roles

  1. implementer

Details : you were told how to fix a problem, and you did as told

Moved deployment from manually-managed hosts to a new Kubernetes cluster.

  1. solver + implementer
@gmolveau
gmolveau / compose.yml
Last active February 7, 2024 12:32
docker compose traefik dns resolving inter containers
View compose.yml
version: "3.3"
services:
traefik:
image: "traefik:v3.0"
container_name: "traefik"
command:
#- "--log.level=DEBUG"
- "--api.dashboard=true"
- "--ping=true"
@gmolveau
gmolveau / envsubst.sh
Last active February 5, 2024 17:12
envsubst alternative in pure bash - replace prefixed environment variables (eg. ${XX_MYVAR}) in a text file
View envsubst.sh
#!/bin/bash
usage() {
echo "Usage: $0 [OPTIONS] [file_path]"
echo "OPTIONS:"
echo " -p, --prefix PREFIX Specify the prefix for environment variables"
echo " -h, --help Show this help message"
echo "If no file_path is provided, the script reads from stdin."
exit 1
}
@gmolveau
gmolveau / dvd_logo_bouncing.html
Created October 7, 2023 06:02
DVD logo bouncing corners changing colors in responsive portable HTML
View dvd_logo_bouncing.html
<html>
<head>
<title>Bouncing DVD Logo</title>
<style>
* {margin:0; padding: 0; color:red;}
</style>
</head>
<body>
<canvas id="tv-screen"></canvas>
@gmolveau
gmolveau / finder_macos_new_text_file_automator.md
Last active September 11, 2023 18:56
Create a new text file in the finder with Automator and Quick Action
View finder_macos_new_text_file_automator.md
  • open automator
  • create new quick action
  • workflow received no input in Finder.app
  • search run apple script and double-click on it
  • replace code with :
tell application "Finder"
    set txt to make new file at (the target of the front window) as alias with properties {name:"newfile.txt"}
 select txt
View bash_best_practices_kvz.sh
#!/usr/bin/env bash
# Bash3 Boilerplate. Copyright (c) 2014, kvz.io
set -o errexit
set -o pipefail
set -o nounset
# set -o xtrace
# Set magic variables for current file & dir
__dir="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
View singlefile-settings-2023-07-26T18_21_36.957Z.json
{
"profiles": {
"__Default_Settings__": {
"removeHiddenElements": true,
"removeUnusedStyles": true,
"removeUnusedFonts": true,
"removeFrames": true,
"removeImports": true,
"compressHTML": true,
"compressCSS": true,
@gmolveau
gmolveau / bash_multiple_commands_parallel.sh
Created July 8, 2023 11:27
bash run multiple commands in parallel
View bash_multiple_commands_parallel.sh
# source : https://stackoverflow.com/a/52033580
# the wait allows COMMAND2 to finish before COMMAND1
# the trap allows the user to kill all the commands with one control-c
(trap 'kill 0' SIGINT; COMMAND1 & COMMAND2 & wait)
@gmolveau
gmolveau / postman_install_without_snap.sh
Created June 14, 2023 13:42
Postman ubuntu install without snap
View postman_install_without_snap.sh
# ubuntu install Postman without snap
DOWNLOAD_PATH="${HOME}/Downloads"
POSTMAN_FILENAME="postman-linux-x64.tar.gz"
POSTMAN_DOWNLOAD_PATH="${DOWNLOAD_PATH}/${POSTMAN_FILENAME}"
POSTMAN_URL="https://dl.pstmn.io/download/latest/linux_64"
wget -c "${POSTMAN_URL}" -O "${POSTMAN_DOWNLOAD_PATH}"
sudo rm -rf /opt/Postman/
@gmolveau
gmolveau / download_docker_macos10.txt
Created April 30, 2023 21:35
macos install docker previous version before macos 11
View download_docker_macos10.txt
Latest docker version to support macos 10 => https://desktop.docker.com/mac/main/amd64/93002/Docker.dmg
https://docs.docker.com/desktop/release-notes/#4150