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
| #!/usr/bin/env python | |
| import http.server | |
| import os | |
| import socketserver | |
| from pathlib import Path | |
| PORT = 8000 | |
| if os.getenv("WORK_DIR") is not None: |
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
| #!/usr/bin/env bash | |
| # Function to log using gum | |
| logger() { | |
| local level msg OPTIND log_file log_dir log_path | |
| level="" | |
| msg="" | |
| log_dir="/tmp" | |
| log_file="gum.log" | |
| log_path="${log_dir}/${log_file}" |
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
| # syntax=docker/dockerfile:1.7.0 | |
| FROM lukemathwalker/cargo-chef:latest-rust-slim-bookworm AS base | |
| WORKDIR /app | |
| RUN apt-get update && apt-get install -y --no-install-recommends \ | |
| libwebkit2gtk-4.0-dev \ | |
| build-essential \ | |
| curl \ |
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
| {%- set excluded_ips = [ | |
| '^192\.168\.8\.', | |
| '^192\.168\.25\.', | |
| '^192\.168\.105\.' | |
| ] -%} | |
| { | |
| {% for host in groups['all'] %} | |
| {%- set ip = hostvars[host]['ansible_host'] | default(host) -%} | |
| {%- if ip is not match(excluded_ips | join('|')) and host != 'localhost' and host != 'lance@orb' %} | |
| "{{ ip }}": { |
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
Show hidden characters
| // https://biomejs.dev/formatter/#options | |
| { | |
| "$schema": "https://biomejs.dev/schemas/1.9.4/schema.json", | |
| "formatter": { | |
| "enabled": true, | |
| "useEditorconfig": true, | |
| "formatWithErrors": true | |
| }, | |
| "json": { |
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
| #!/usr/bin/env python | |
| import docker | |
| client = docker.from_env() | |
| container = client.containers.run("ubuntu:latest", | |
| command=["echo", "hello", "world!"], | |
| detach=True, | |
| remove=False, |
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
| #!/usr/bin/env bash | |
| # shellcheck disable=SC2155 | |
| # Environment variable overrides with defaults | |
| OUTPUT_DIR="${OUTPUT_DIR:-${HOME}/Downloads/git_archive}" | |
| ARCHIVE_FORMAT="${FORMAT:-zip}" | |
| MAX_DEPTH="${MAX_DEPTH:-2}" | |
| # Create output directory if it doesn't exist |
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
| #!/usr/bin/env bash | |
| set -eo pipefail | |
| # Default values | |
| PACKAGE_NAME="" | |
| USER_NAME="" | |
| DRY_RUN=false | |
| VERBOSE=false |
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
| VERSION 0.8 | |
| ARG --global APP_NAME="hello_rust" | |
| ARG --global PROFILE=release | |
| all: | |
| BUILD \ | |
| --platform=linux/amd64 \ | |
| --platform=linux/arm64 \ | |
| +docker |
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
| #!/usr/bin/env bash | |
| set -e | |
| # Clean up function | |
| cleanup() { | |
| echo "Cleaning up existing cluster..." | |
| kind delete cluster | |
| } |