Skip to content

Instantly share code, notes, and snippets.

View ScriptAutomate's full-sized avatar
:shipit:
Automating All The Things

Derek Ardolf ScriptAutomate

:shipit:
Automating All The Things
View GitHub Profile
@ScriptAutomate
ScriptAutomate / sops.Dockerfile
Last active September 8, 2024 17:39
SOPS container creation, using slsa-verifier and cosign to ensure SOPS integrity and artifact provenance
FROM ubuntu:24.04
ARG SLSA_VERIFIER_VERSION=2.6.0
ARG COSIGN_VERSION=2.4.0
ARG SOPS_VERSION=3.9.0
# Prereqs for validation
## slsa-verifier
ADD https://github.com/slsa-framework/slsa-verifier/releases/download/v${SLSA_VERIFIER_VERSION}/slsa-verifier-linux-amd64 /tmp/slsa-verifier-linux-amd64
ADD https://github.com/slsa-framework/slsa-verifier/releases/download/v${SLSA_VERIFIER_VERSION}/slsa-verifier-linux-amd64.intoto.jsonl /tmp/slsa-verifier-linux-amd64.intoto.jsonl
ADD https://raw.githubusercontent.com/slsa-framework/slsa-verifier/main/SHA256SUM.md /tmp/slsa-SHA256SUM.md
@ScriptAutomate
ScriptAutomate / awscli.sls
Created August 16, 2024 05:38
Install AWS CLI via Salt State
{% set user_name = salt['pillar.get']('common:lookup:user') %}
awscli-extract:
archive.extracted:
- name: /home/{{ user_name }}/Downloads/awscli
- if_missing: /home/{{ user_name }}/Downloads/awscli/aws
- archive_format: zip
- source: https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip
- user: {{ user_name }}
- group: {{ user_name }}
- skip_verify: True
@ScriptAutomate
ScriptAutomate / README.md
Last active May 8, 2024 20:11
Slack Export Cleanup / Prep Scripts

Slack Export Cleanup / Prep Scripts

These three files were used to help clean up a Slack Workspace channel export prior to importing into a Discord server.

Ultimately, the Salt Project Slack Archive Export was imported into the new Salt Project Discord Server:

Prereqs

@ScriptAutomate
ScriptAutomate / output-example.log
Last active March 23, 2023 21:45
Test OpenAPI Whisper: Record and Transcribe via Terminal
[00:00.000 --> 00:17.320] I'm currently testing Whisper on my desktop as a way to eventually share with the linking
[00:17.320 --> 00:20.080] your thinking community.
[00:20.080 --> 00:28.720] This is just a way to show different timestamps and general display ability and seeing how
[00:28.720 --> 00:34.000] this could look as an easy note taking solution.
[00:34.000 --> 00:38.240] I for one think this is a rather cool piece of software that I could simply run from my
[00:38.240 --> 00:40.960] terminal of my Linux desktop.
@ScriptAutomate
ScriptAutomate / dendron.yml
Last active November 23, 2022 06:58
Preferred way of working with multi-vault, self contained vault workflows. Inlcudes explanation of multi-vault layout with self contained vaults.
dev:
enablePreviewV2: true
# Ensure selfcontainedvaults enabled
enableSelfContainedVaults: true
enableExportPodV2: true
commands:
lookup:
note:
# Enables vaultSelectionModeOnCreate
# https://wiki.dendron.so/notes/F9LWJEjscrGkxnYi2JNby/#confirmvaultoncreate
@ScriptAutomate
ScriptAutomate / markdown.json
Last active June 13, 2022 15:05
Dendron Snippet: Insert Timestamp (good for interstitial journaling)
{
"g.time": {
"prefix": "-t",
"body": [
"- $CURRENT_YEAR-$CURRENT_MONTH-$CURRENT_DATE $CURRENT_HOUR:$CURRENT_MINUTE: "
],
"description": "Insert timestamp. Good for interstitial journaling."
}
}
@ScriptAutomate
ScriptAutomate / wiki-to-dendron.py
Last active March 22, 2022 19:33
Basic Python script for downloading a Wiki article and converting to a Dendron note
from datetime import datetime
# Requires third-party Python packages
# pip install mediawiki
# pip install shortuuid
from mediawiki import MediaWiki
import shortuuid
@ScriptAutomate
ScriptAutomate / dropdown.md
Created February 17, 2022 17:28 — forked from citrusui/dropdown.md
"Dropdowns" in Markdown
How do I dropdown?
This is how you dropdown.

<details>
<summary>How do I dropdown?</summary>
<br>
This is how you dropdown.
@ScriptAutomate
ScriptAutomate / ConvertTo-Markdown.ps1
Last active February 9, 2022 15:40 — forked from Matticusau/ConvertTo-Markdown.ps1
ConvertTo-Markdown
Function ConvertTo-Markdown {
<#
.Synopsis
Converts a PowerShell object to a Markdown table.
.Description
Converts a PowerShell object to a Markdown table.
.Parameter InputObject
PowerShell object to be converted
.Example
ConvertTo-Markdown -InputObject (Get-Service)
@ScriptAutomate
ScriptAutomate / .gitlab-ci.yml
Last active February 9, 2022 22:48
GitLab CI Publishing Dendron Proof-Of-Concept
---
stages:
- build-docs
- publish-docs
build-docs-html:
stage: build-docs
image: node:lts-bullseye
# Cache modules using lock file
cache: