Build the apps/snotes project as a container image tagged docker.io/localhost/snotes:latest,
import it directly into k0s containerd (no SSH needed — same machine), and create Flux-managed
Kubernetes manifests in clusters/thelab/snotes/ following the clusters/thelab/apps/ pattern.
Git sync is explicitly disabled via env var. imagePullPolicy is Never so k0s uses the locally
imported 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
| apiVersion: k0sctl.k0sproject.io/v1beta1 | |
| kind: Cluster | |
| metadata: | |
| name: k0s-cluster | |
| user: admin | |
| spec: | |
| hosts: | |
| - ssh: | |
| address: localhost | |
| user: root |
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
| init: | |
| colima start argocd-selfmanaged --kubernetes | |
| kubectl-get-nodes: | |
| kubectl get nodes | |
| kubectl get pods -A | |
| kubectl-apply-argocd: | |
| kubectl create namespace argocd | |
| kubectl apply -n argocd -f https://raw.githubusercontent.com/argoproj/argo-cd/stable/manifests/install.yaml |
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
| target: | |
| SELECTED=`cat main.tf | grep resource | tr -d '"' | awk '{ print $$2 "." $$3 }' | fzf` ; \ | |
| terraform apply -target=$$SELECTED |
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
| package main | |
| import ( | |
| "encoding/json" | |
| "os" | |
| "path/filepath" | |
| ) | |
| const ( | |
| output = "shortcuts" |
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
| { | |
| "aws-cli-reference": "https://docs.aws.amazon.com/cli/latest/reference/index.html", | |
| "aws-cli-acm": "https://docs.aws.amazon.com/cli/latest/reference/acm/index.html", | |
| "aws-cli-acm-pca": "https://docs.aws.amazon.com/cli/latest/reference/acm-pca/index.html", | |
| "aws-cli-alexaforbusiness": "https://docs.aws.amazon.com/cli/latest/reference/alexaforbusiness/index.html", | |
| "aws-cli-amplify": "https://docs.aws.amazon.com/cli/latest/reference/amplify/index.html", | |
| "aws-cli-apigateway": "https://docs.aws.amazon.com/cli/latest/reference/apigateway/index.html", | |
| "aws-cli-apigatewaymanagementapi": "https://docs.aws.amazon.com/cli/latest/reference/apigatewaymanagementapi/index.html", | |
| "aws-cli-apigatewayv2": "https://docs.aws.amazon.com/cli/latest/reference/apigatewayv2/index.html", | |
| "aws-cli-application-autoscaling": "https://docs.aws.amazon.com/cli/latest/reference/application-autoscaling/index.html", |
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
| package main | |
| import ( | |
| "fmt" | |
| "os/exec" | |
| "strings" | |
| "strconv" | |
| "net" | |
| ) |
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
| # terraform.vars | |
| rules = [ | |
| { | |
| api_groups = [""] | |
| resources = ["pods","services","deployments","jobs"] | |
| verbs = ["*"] | |
| }, | |
| { | |
| api_groups = [""] | |
| resources = ["namespaces"] |
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
| apiVersion: v1 | |
| kind: ServiceAccount | |
| metadata: | |
| name: myapp | |
| namespace: mynamespace | |
| --- | |
| kind: ClusterRole | |
| apiVersion: rbac.authorization.k8s.io/v1 | |
| metadata: | |
| namespace: mynamespace |
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
| locals { | |
| policies_arns = { | |
| for item in aws_iam_policy.policy : | |
| item.name => item.arn | |
| } | |
| users_attachment = distinct( | |
| flatten([ | |
| for item in var.policies : [ | |
| for user in item.users_to_attach : { |
NewerOlder