What if we can use GitHub Container Registry as a GitHub Action Registry (which is missing at the moment). This entails using the GitHub CLI to package a docker-based GitHub Actions and publish the action image with everything necessary to make it discoverable by the GitHub Workflow Engine.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Generate a new key | |
openssl genrsa -out server.key 2048 | |
# Generate a new CSR | |
openssl req -sha256 -new -key server.key -out server.csr | |
# Check certificate against CA | |
openssl verify -verbose -CApath ./CA/ -CAfile ./CA/cacert.pem cert.pem | |
# Self Signed |
This post described how to create an application with mithril 0.2.x. Now that ver 1.0 is out, some things are a little differnent.
The example is updated with the current version of mithril, though.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# ALGORITHM | |
# | |
# | |
# Function to handle image | |
# | |
# 1. load_image("/checmi/vers/fichier") -> np.darray (image) | |
# 2. move_image(image: np.darray, (dy: int, dx: int)) -> np.darray (image) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export let errorRate = new Rate("errors"); | |
export default function() { | |
let res = http.get("https://httpbin.org/status/200,400") | |
let requestTimedout = check(res, {"exceeds timeout of 1500ms": (r) => r.timings.duration < 1500}); | |
let requestTimedout = !(checkRequestSucceeded) | |
if (requestTimedout) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import time | |
DEFAULT_TIMEOUT_IN_SEC = 1 | |
DEFAULT_MAX_ATTEMPTS = 5 | |
def retry(**kwargs): | |
def inner(func): | |
attempt = 0 | |
max_attempts = kwargs["attempts"] if kwargs["attempts"] else DEFAULT_MAX_ATTEMPTS |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
find src/modules \ | |
-type d\ | |
-not -path src/modules\ | |
-print0 \ | |
| $_XARGS_CMD -I module bash -c 'terraform-docs markdown "module" > "module"/README.md' | |
Check $? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
color: | |
interactive-color: | |
background-color: | |
text-color: | |
font: | |
family: | |
size: | |
line-height: | |
typography: | |
border: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# | |
# Bash `flock` example. | |
# Works on: Linux, BSD | |
# Doesn't work on: MacOS | |
# The file which represent the lock. | |
LOCKFILE="`basename $0`.lock" | |
# Timeout in seconds. |