Skip to content

Instantly share code, notes, and snippets.

- name: vapp1
metadata:
a: 1
b: 2
virtuals:
- name: v1
- name: v2
- name: v3
- name: vapp2
metadata:
data "cloudinit_config" "this" {
base64_encode = true
gzip = false
boundary = "//"
part {
content_type = "text/x-shellscript"
content = <<-EOT
set -x
KUBELET_CONFIG=/etc/kubernetes/kubelet/kubelet-config.json
{
"cniVersion": "0.3.1",
"name": "cilium",
"plugins": [
{
"cniVersion": "0.3.1",
"eni": {
"first-interface-index": 1,
"subnet-tags": {
"Cilium": "Owned",
kubeProxyReplacement: strict
k8sServicePort: 443
bpf:
masquerade: true
extraConfig:
install-no-conntrack-iptables-rules: "true"
bandwidthManager:
enabled: true
eni:
enabled: true
$ cat Dockerfile
FROM docker.io/node:18.18.2
LABEL ttt=aa
WORKDIR /app
COPY ./yarn.lock ./
COPY ./package.json ./
RUN yarn install --frozen-lockfile --ignore-platform
RUN find /usr/local/share/.cache/yarn
RUN ls -la /usr/local/share/.cache/yarn/v6/npm-@parcel-watcher-win32-x64-2.3.0-14e7246289861acc589fd608de39fe5d8b4bb0a7-integrity/node_modules/@parcel/watcher-win32-x64/
/*
duration: 72.267 ms
parameters: $1 = 'networking', $2 = 'random-string', $3 = 'group', $4 = '{"\"group-name\""}'
*/
WITH inactive_nodes AS (
SELECT
certname
FROM
certnames
WHERE
/*
duration: 4210.015 ms
parameters: $1 = 'networking', $2 = 'networking', $3 = 'networking', $4 = 'networking', $5 = 'group', $6 = '{"\"group-name\""}'
*/
WITH inactive_nodes AS (
SELECT
certname
FROM
certnames
WHERE
@identw
identw / stack.tm.hcl
Created September 4, 2023 08:10
terramate example tm_dynamic how to generate few resources for each provider
globals {
providers = ["name1", "name2"]
}
generate_hcl "example.tf" {
content {
tm_dynamic "resource1" {
for_each = tm_toset(global.providers)
iterator = i
$ cat example.tf
// TERRAMATE: GENERATED AUTOMATICALLY DO NOT EDIT
resource1 {
provider = "name1"
}
resource1 {
provider = "name2"
}
resource2 {
globals {
providers = ["name1", "name2"]
}
generate_hcl "example.tf" {
content {
tm_dynamic "resource1" {
for_each = tm_toset(global.providers)
iterator = i