deployment.c4
1 specification { 2 deploymentNode node 3 deploymentNode zone 4 deploymentNode vendor 5 deploymentNode hardware 6 deploymentNode service 7 deploymentNode environment { 8 style { 9 color gray 10 } 11 } 12 } 13 14 deployment { 15 person = node "Person" { 16 instanceOf person 17 } 18 19 owner = node "Owner" { 20 style { 21 color red 22 } 23 instanceOf person 24 } 25 26 github = vendor "GitHub" { 27 style { 28 color slate 29 } 30 instanceOf vendors.github 31 } 32 33 microvisor = node "Microvisor" { 34 instanceOf microvisor 35 } 36 37 // pulumi-cloud = vendor "Pulumi Cloud" { 38 // instanceOf vendors.pulumi 39 // } 40 41 google = zone "Google Cloud Auth Platform" { 42 link : https://cloud.google.com "Website" 43 icon: tech:google-cloud 44 style { 45 color green 46 shape browser 47 } 48 instanceOf vendors.google.cloud.auth-platform 49 } 50 51 cloudflare = zone "Cloudflare" { 52 icon tech:cloudflare 53 style { 54 color amber 55 } 56 instanceOf vendors.cloudflare.dns 57 instanceOf vendors.cloudflare.tunnels 58 } 59 60 tailscale = zone "Tailscale" { 61 style { 62 color gray 63 } 64 acl = node "ACL" { 65 icon: @/tailscale-symbol.png 66 link : https://tailscale.com "Website" 67 style { 68 color gray-800 69 shape storage 70 } 71 -> coordination-server { 72 style { 73 line solid 74 } 75 } 76 } 77 78 coordination-server = node "Coordination Server" { 79 icon: @/tailscale-symbol.png 80 link : https://tailscale.com "Website" 81 style { 82 color gray-800 83 shape queue 84 } 85 } 86 87 } 88 89 90 production = environment "Production" { 91 style { 92 color red 93 } 94 95 ottawa-east-1 = zone "Ottawa East 1" { 96 icon https://upload.wikimedia.org/wikipedia/commons/thumb/5/5f/Flag_of_Ottawa%2C_Ontario.svg/2560px-Flag_of_Ottawa%2C_Ontario.svg.png 97 style { 98 color green 99 } 100 hardware framework-desktop "Framework Desktop" { 101 icon https://static.cdnlogo.com/logos/f/78/framework-computer.svg 102 style { 103 color yellow 104 } 105 106 instanceOf microvisor.nixos "NixOS" 107 instanceOf vendors.tailscale "Tailscale Client" 108 cloudflared = instanceOf vendors.cloudflare.tunnels "Cloudflared" 109 110 caddy = service "Caddy" { 111 link https://caddyserver.com "Website" 112 icon https://avatars.githubusercontent.com/u/12955528?s=200&v=4 113 style { 114 color green 115 } 116 instanceOf openws.caddy.virtual-hosts 117 instanceOf openws.caddy.reverse-proxy 118 } 119 120 instanceOf openws.homepage 121 instanceOf openws.docs 122 instanceOf openws.open-webui 123 instanceOf openws.ollama 124 instanceOf microvisor.sqlite 125 instanceOf microvisor.docker 126 127 cloudflared -> virtual-hosts 128 virtual-hosts -> reverse-proxy 129 reverse-proxy -> homepage 130 reverse-proxy -> open-webui 131 reverse-proxy -> docs 132 reverse-proxy -> docker 133 134 open-webui -> ollama { 135 technology "REST API" 136 style { 137 line solid 138 } 139 } 140 open-webui -> google { 141 technology "OAuth 2.0" 142 style { 143 head diamond 144 tail diamond 145 line dotted 146 color red 147 } 148 } 149 ollama -> sqlite { 150 style { 151 color sky 152 tail normal 153 } 154 } 155 156 } 157 158 hardware framework-16 "Framework 16" { 159 style { 160 color yellow 161 } 162 icon https://static.cdnlogo.com/logos/f/78/framework-computer.svg 163 164 instanceOf apollyon-linux 165 instanceOf vendors.tailscale "Tailscale Client" 166 instanceOf vendors.netdata 167 } 168 169 hardware hp-elitebook-820-g2 "HP Elitebook 820 G2" { 170 style { 171 color red 172 } 173 icon @/doombsd-symbol-orb.svg 174 175 instanceOf doombsd 176 instanceOf vendors.tailscale "Tailscale Client" 177 } 178 179 hardware esp32-s3-devkit-c-1 { 180 181 } 182 } 183 184 montreal = zone "Montreal" { 185 oracle = vendor "Oracle" { 186 style { 187 color red 188 } 189 icon tech:oracle 190 node vm { 191 instanceOf vendors.oci.virtual-machines 192 instanceOf vendors.tailscale 193 } 194 } 195 } 196 197 toronto = zone "Toronto" { 198 digitalocean = zone "DigitalOcean" { 199 icon tech:digital-ocean 200 instanceOf vendors.digitalocean.droplets 201 } 202 } 203 204 tailscale.coordination-server -> framework-desktop.tailscale "SSH" { 205 style { 206 line dotted 207 } 208 } 209 tailscale.coordination-server -> hp-elitebook-820-g2.tailscale "SSH" { 210 style { 211 line dotted 212 } 213 } 214 tailscale.coordination-server -> framework-16.tailscale "SSH" { 215 style { 216 line dotted 217 } 218 } 219 // tailscale.coordination-server -> oracle.vm.tailscale "SSH" 220 221 person -> cloudflare "visits" { 222 style { 223 color blue 224 } 225 technology "HTTPS" 226 } 227 228 owner -> cloudflare "visits" { 229 style { 230 color blue 231 } 232 technology "HTTPS" 233 } 234 235 owner -> github { 236 technology "OAuth 2.0" 237 style { 238 head diamond 239 tail diamond 240 color red 241 line dotted 242 } 243 } 244 github -> tailscale { 245 style { 246 color green 247 line dotted 248 } 249 } 250 251 cloudflare.dns -> cloudflare.tunnels { 252 style { 253 color yellow 254 line solid 255 } 256 } 257 cloudflare.tunnels -> framework-desktop.cloudflared { 258 style { 259 color yellow 260 line solid 261 } 262 } 263 264 microvisor -> nixos 265 266 } 267 }