The design and endpoint concepts are inspired by AWS’s documentation for creating an external key store. AWS XKS Documentation
Details about managing keys and using cryptographic operations with Azure Key Vault Azure Key Vault Keys Overview.
AWSTemplateFormatVersion: '2010-09-09' | |
Description: Test substitution logic for IP construction with dummy resource. | |
Resources: | |
DummyResource: | |
Type: AWS::CloudFormation::WaitConditionHandle | |
Outputs: | |
FabricComponentsStaticIP: | |
Value: !Sub |
const redis = require('redis'); | |
const readline = require('readline'); | |
async function connectRedis(host, port, db, password) { | |
const client = redis.createClient({ | |
socket: { host, port }, | |
database: db, | |
password | |
}); | |
await client.connect(); |
# define functions to run the ocr, | |
# annotate the images with the bounding boxes | |
# consolidate the results to a dataframe | |
# and iterate over a folder of images | |
from PIL import Image, ImageDraw | |
import pandas as pd | |
from paddleocr import PaddleOCR | |
import os | |
import traceback |
while true; do | |
curl -o /dev/null -s -w "%{http_code}, %{time_total}s\n" \ | |
http://169.254.170.2$AWS_CONTAINER_CREDENTIALS_RELATIVE_URI | |
sleep 5 | |
done |
#!/bin/bash | |
echo "Updating package lists..." | |
dnf update -y | |
echo "Installing required dependencies..." | |
dnf install -y perl perl-core perl-FindBin perl-Time-HiRes perl-JSON \ | |
perl-Digest-MD5 perl-Text-CSV perl-LWP-Protocol-https \ | |
perl-DBI perl-DBD-Pg tar gzip make |
#!/bin/bash | |
set -euo pipefail | |
# Check for required commands: aws and jq. | |
command -v aws >/dev/null 2>&1 || { echo "aws CLI is required but not installed. Exiting." >&2; exit 1; } | |
command -v jq >/dev/null 2>&1 || { echo "jq is required but not installed. Exiting." >&2; exit 1; } | |
usage() { | |
cat <<EOF | |
Usage: $0 [secret_name] |
# install pipx | |
python -m pip install --user pipx | |
python -m pipx ensurepath | |
sudo pipx ensurepath --global | |
# install jupyterlab | |
pipx install jupyterlab --include-deps | |
pipx ensurepath | |
# add common dependencies |
AWSTemplateFormatVersion: 2010-09-09 | |
Transform: AWS::LanguageExtensions | |
Parameters: | |
AlarmLambdaPairs: | |
Type: CommaDelimitedList | |
Description: | | |
Comma-separated "prefix:lambdaName" pairs. Example: "PrefixA:MyLambdaA,PrefixB:MyLambdaB" | |
Default: PrefixA:MyLambdaA,PrefixB:MyLambdaB |
The design and endpoint concepts are inspired by AWS’s documentation for creating an external key store. AWS XKS Documentation
Details about managing keys and using cryptographic operations with Azure Key Vault Azure Key Vault Keys Overview.
import boto3 | |
def delete_old_nodejs_lambdas(): | |
client = boto3.client("lambda") | |
deprecated_runtimes = {"nodejs12.x", "nodejs14.x", "nodejs16.x"} | |
# Paginate through all Lambda functions | |
paginator = client.get_paginator("list_functions") | |
page_iterator = paginator.paginate() | |