Skip to content

Instantly share code, notes, and snippets.

@pmdroid
Created April 3, 2026 21:06
Show Gist options
  • Select an option

  • Save pmdroid/6ad6290171061c128d55233f89b6395b to your computer and use it in GitHub Desktop.

Select an option

Save pmdroid/6ad6290171061c128d55233f89b6395b to your computer and use it in GitHub Desktop.
temp.json
{
"version": 1,
"templates": [
{
"slug": "code-server",
"name": "Code Server",
"description": "VS Code in the browser. Access a full development environment from any device.",
"category": "development",
"icon": "code",
"imageSlug": "ubuntu-24.04-arm64",
"cpuCount": 2,
"memoryMB": 2048,
"diskSizeGB": 20,
"portForwards": [
{ "protocol": "tcp", "hostPort": 8080, "guestPort": 8080 }
],
"inputs": [
{
"id": "username",
"label": "Username",
"type": "text",
"default": "coder",
"required": true,
"placeholder": "coder"
},
{
"id": "password",
"label": "Password",
"type": "password",
"required": true,
"placeholder": "Choose a strong password",
"minLength": 8
},
{
"id": "ssh_keys",
"label": "SSH Public Keys",
"type": "textarea",
"required": false,
"placeholder": "ssh-ed25519 AAAA... (one per line)"
}
],
"userDataTemplate": "#cloud-config\nusers:\n - name: {{username}}\n shell: /bin/bash\n sudo: ALL=(ALL) NOPASSWD:ALL\n lock_passwd: false\n passwd: {{password_hash}}\n ssh_authorized_keys:\n{{ssh_keys_yaml}}\npackage_update: true\npackage_upgrade: true\npackages:\n - curl\n - git\n - build-essential\nruncmd:\n - curl -fsSL https://code-server.dev/install.sh | sh\n - systemctl enable --now code-server@{{username}}\n - |\n mkdir -p /home/{{username}}/.config/code-server\n cat > /home/{{username}}/.config/code-server/config.yaml <<CEOF\n bind-addr: 0.0.0.0:8080\n auth: password\n password: {{password}}\n cert: false\n CEOF\n chown -R {{username}}:{{username}} /home/{{username}}/.config\n - systemctl restart code-server@{{username}}\n"
},
{
"slug": "docker-host",
"name": "Docker Host",
"description": "Ready-to-use Docker engine with Portainer for web-based container management.",
"category": "infrastructure",
"icon": "container",
"imageSlug": "ubuntu-24.04-arm64",
"cpuCount": 2,
"memoryMB": 2048,
"diskSizeGB": 30,
"portForwards": [
{ "protocol": "tcp", "hostPort": 9443, "guestPort": 9443 },
{ "protocol": "tcp", "hostPort": 9000, "guestPort": 9000 }
],
"inputs": [
{
"id": "username",
"label": "Username",
"type": "text",
"default": "docker",
"required": true,
"placeholder": "docker"
},
{
"id": "password",
"label": "Password",
"type": "password",
"required": true,
"placeholder": "Choose a strong password",
"minLength": 8
},
{
"id": "ssh_keys",
"label": "SSH Public Keys",
"type": "textarea",
"required": false,
"placeholder": "ssh-ed25519 AAAA... (one per line)"
}
],
"userDataTemplate": "#cloud-config\nusers:\n - name: {{username}}\n shell: /bin/bash\n sudo: ALL=(ALL) NOPASSWD:ALL\n lock_passwd: false\n passwd: {{password_hash}}\n groups: docker\n ssh_authorized_keys:\n{{ssh_keys_yaml}}\npackage_update: true\npackage_upgrade: true\npackages:\n - ca-certificates\n - curl\n - gnupg\nruncmd:\n - install -m 0755 -d /etc/apt/keyrings\n - curl -fsSL https://download.docker.com/linux/ubuntu/gpg | gpg --dearmor -o /etc/apt/keyrings/docker.gpg\n - chmod a+r /etc/apt/keyrings/docker.gpg\n - echo \"deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu $(. /etc/os-release && echo $VERSION_CODENAME) stable\" > /etc/apt/sources.list.d/docker.list\n - apt-get update\n - apt-get install -y docker-ce docker-ce-cli containerd.io docker-compose-plugin\n - systemctl enable --now docker\n - docker run -d --name portainer --restart=always -p 9443:9443 -p 9000:9000 -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer-ce:latest\n"
},
{
"slug": "home-assistant",
"name": "Home Assistant",
"description": "Smart home automation platform. Uses the official Home Assistant OS image.",
"category": "home-automation",
"icon": "home",
"imageSlug": "haos-17.1-arm64",
"cpuCount": 2,
"memoryMB": 2048,
"diskSizeGB": 32,
"portForwards": [
{ "protocol": "tcp", "hostPort": 8123, "guestPort": 8123 }
],
"inputs": [],
"userDataTemplate": ""
},
{
"slug": "pi-hole",
"name": "Pi-hole",
"description": "Network-wide DNS ad blocker. Lightweight and effective.",
"category": "networking",
"icon": "shield",
"imageSlug": "ubuntu-24.04-arm64",
"cpuCount": 1,
"memoryMB": 512,
"diskSizeGB": 8,
"portForwards": [],
"networkMode": "bridged",
"inputs": [
{
"id": "username",
"label": "Username",
"type": "text",
"default": "pihole",
"required": true,
"placeholder": "pihole"
},
{
"id": "password",
"label": "Web Admin Password",
"type": "password",
"required": true,
"placeholder": "Admin panel password",
"minLength": 6
},
{
"id": "ssh_keys",
"label": "SSH Public Keys",
"type": "textarea",
"required": false,
"placeholder": "ssh-ed25519 AAAA... (one per line)"
}
],
"userDataTemplate": "#cloud-config\nusers:\n - name: {{username}}\n shell: /bin/bash\n sudo: ALL=(ALL) NOPASSWD:ALL\n lock_passwd: false\n passwd: {{password_hash}}\n ssh_authorized_keys:\n{{ssh_keys_yaml}}\npackage_update: true\npackage_upgrade: true\npackages:\n - curl\nruncmd:\n - mkdir -p /etc/pihole\n - |\n cat > /etc/pihole/setupVars.conf <<PVEOF\n PIHOLE_INTERFACE=eth0\n QUERY_LOGGING=true\n INSTALL_WEB_SERVER=true\n INSTALL_WEB_INTERFACE=true\n LIGHTTPD_ENABLED=true\n WEBPASSWORD=$(echo -n {{password}} | sha256sum | awk '{print $1}' | sha256sum | awk '{print $1}')\n BLOCKING_ENABLED=true\n PIHOLE_DNS_1=1.1.1.1\n PIHOLE_DNS_2=8.8.8.8\n PVEOF\n - curl -sSL https://install.pi-hole.net | bash /dev/stdin --unattended\n"
},
{
"slug": "nextcloud",
"name": "Nextcloud",
"description": "Self-hosted file sync, sharing, and collaboration platform.",
"category": "cloud-storage",
"icon": "cloud",
"imageSlug": "ubuntu-24.04-arm64",
"cpuCount": 2,
"memoryMB": 2048,
"diskSizeGB": 40,
"portForwards": [
{ "protocol": "tcp", "hostPort": 8443, "guestPort": 443 },
{ "protocol": "tcp", "hostPort": 8880, "guestPort": 80 }
],
"inputs": [
{
"id": "username",
"label": "System Username",
"type": "text",
"default": "nextcloud",
"required": true,
"placeholder": "nextcloud"
},
{
"id": "password",
"label": "Password",
"type": "password",
"required": true,
"placeholder": "Used for system user and Nextcloud admin",
"minLength": 8
},
{
"id": "admin_user",
"label": "Nextcloud Admin Username",
"type": "text",
"default": "admin",
"required": true,
"placeholder": "admin"
},
{
"id": "ssh_keys",
"label": "SSH Public Keys",
"type": "textarea",
"required": false,
"placeholder": "ssh-ed25519 AAAA... (one per line)"
}
],
"userDataTemplate": "#cloud-config\nusers:\n - name: {{username}}\n shell: /bin/bash\n sudo: ALL=(ALL) NOPASSWD:ALL\n lock_passwd: false\n passwd: {{password_hash}}\n ssh_authorized_keys:\n{{ssh_keys_yaml}}\npackage_update: true\npackage_upgrade: true\npackages:\n - apache2\n - mariadb-server\n - php\n - php-gd\n - php-mysql\n - php-curl\n - php-mbstring\n - php-intl\n - php-gmp\n - php-bcmath\n - php-xml\n - php-imagick\n - php-zip\n - php-apcu\n - libapache2-mod-php\n - unzip\n - curl\nruncmd:\n - mysql -e \"CREATE DATABASE nextcloud;\"\n - mysql -e \"CREATE USER 'nextcloud'@'localhost' IDENTIFIED BY '{{password}}';\"\n - mysql -e \"GRANT ALL PRIVILEGES ON nextcloud.* TO 'nextcloud'@'localhost'; FLUSH PRIVILEGES;\"\n - curl -Lo /tmp/nextcloud.zip https://download.nextcloud.com/server/releases/latest.zip\n - unzip -q /tmp/nextcloud.zip -d /var/www/\n - chown -R www-data:www-data /var/www/nextcloud\n - |\n cat > /etc/apache2/sites-available/nextcloud.conf <<NCEOF\n <VirtualHost *:80>\n DocumentRoot /var/www/nextcloud\n <Directory /var/www/nextcloud>\n Require all granted\n AllowOverride All\n Options FollowSymLinks MultiViews\n </Directory>\n </VirtualHost>\n NCEOF\n - a2ensite nextcloud.conf\n - a2dissite 000-default.conf\n - a2enmod rewrite headers env dir mime\n - systemctl restart apache2\n - sudo -u www-data php /var/www/nextcloud/occ maintenance:install --database mysql --database-name nextcloud --database-user nextcloud --database-pass {{password}} --admin-user {{admin_user}} --admin-pass {{password}}\n - sudo -u www-data php /var/www/nextcloud/occ config:system:set trusted_domains 0 --value='*'\n"
},
{
"slug": "plain-linux",
"name": "Plain Linux",
"description": "Minimal Ubuntu server with a user account and SSH access. A clean slate for any project.",
"category": "general",
"icon": "terminal",
"imageSlug": "ubuntu-24.04-arm64",
"cpuCount": 2,
"memoryMB": 1024,
"diskSizeGB": 10,
"portForwards": [],
"inputs": [
{
"id": "username",
"label": "Username",
"type": "text",
"default": "ubuntu",
"required": true,
"placeholder": "ubuntu"
},
{
"id": "password",
"label": "Password",
"type": "password",
"required": true,
"placeholder": "Choose a password",
"minLength": 6
},
{
"id": "ssh_keys",
"label": "SSH Public Keys",
"type": "textarea",
"required": false,
"placeholder": "ssh-ed25519 AAAA... (one per line)"
},
{
"id": "extra_packages",
"label": "Extra Packages",
"type": "text",
"required": false,
"placeholder": "vim htop tmux (space-separated)"
}
],
"userDataTemplate": "#cloud-config\nusers:\n - name: {{username}}\n shell: /bin/bash\n sudo: ALL=(ALL) NOPASSWD:ALL\n lock_passwd: false\n passwd: {{password_hash}}\n ssh_authorized_keys:\n{{ssh_keys_yaml}}\npackage_update: true\npackage_upgrade: true\npackages:\n - curl\n - wget\n - git\n{{extra_packages_yaml}}\nruncmd:\n - echo \"VM provisioned by BarkVisor template\" > /etc/motd\n"
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment