[{"data":1,"prerenderedAt":590},["ShallowReactive",2],{"navigation_docs":3,"section-navigation-docs":130,"-docs-variables":164,"-docs-variables-surround":497,"doc-previews":502},[4,8,50,54,58,62,66,70,74,78,82,86,90,94,98,102,106,110,114,118,122,126],{"title":5,"path":6,"stem":7},"Quickstart","\u002Fdocs\u002Fquickstart","docs\u002F01.quickstart",{"title":9,"path":10,"stem":11,"children":12},"Guides","\u002Fdocs\u002Fguides","docs\u002F02.guides\u002Findex",[13,14,18,22,26,30,34,38,42,46],{"title":9,"path":10,"stem":11},{"title":15,"path":16,"stem":17},"Next.js","\u002Fdocs\u002Fguides\u002Fnextjs","docs\u002F02.guides\u002F1.nextjs",{"title":19,"path":20,"stem":21},"Nuxt","\u002Fdocs\u002Fguides\u002Fnuxt","docs\u002F02.guides\u002F2.nuxt",{"title":23,"path":24,"stem":25},"SvelteKit","\u002Fdocs\u002Fguides\u002Fsveltekit","docs\u002F02.guides\u002F3.sveltekit",{"title":27,"path":28,"stem":29},"Astro","\u002Fdocs\u002Fguides\u002Fastro","docs\u002F02.guides\u002F4.astro",{"title":31,"path":32,"stem":33},"Express","\u002Fdocs\u002Fguides\u002Fexpress","docs\u002F02.guides\u002F5.express",{"title":35,"path":36,"stem":37},"FastAPI","\u002Fdocs\u002Fguides\u002Ffastapi","docs\u002F02.guides\u002F6.fastapi",{"title":39,"path":40,"stem":41},"Django","\u002Fdocs\u002Fguides\u002Fdjango","docs\u002F02.guides\u002F7.django",{"title":43,"path":44,"stem":45},"Laravel","\u002Fdocs\u002Fguides\u002Flaravel","docs\u002F02.guides\u002F8.laravel",{"title":47,"path":48,"stem":49},"Go","\u002Fdocs\u002Fguides\u002Fgo","docs\u002F02.guides\u002F9.go",{"title":51,"path":52,"stem":53},"Services","\u002Fdocs\u002Fservices","docs\u002F03.services",{"title":55,"path":56,"stem":57},"Deployments","\u002Fdocs\u002Fdeployments","docs\u002F04.deployments",{"title":59,"path":60,"stem":61},"Builds","\u002Fdocs\u002Fbuilds","docs\u002F05.builds",{"title":63,"path":64,"stem":65},"Variables","\u002Fdocs\u002Fvariables","docs\u002F06.variables",{"title":67,"path":68,"stem":69},"Domains","\u002Fdocs\u002Fdomains","docs\u002F07.domains",{"title":71,"path":72,"stem":73},"PostgreSQL","\u002Fdocs\u002Fpostgres","docs\u002F08.postgres",{"title":75,"path":76,"stem":77},"Object storage","\u002Fdocs\u002Fobject-storage","docs\u002F09.object-storage",{"title":79,"path":80,"stem":81},"Volumes","\u002Fdocs\u002Fvolumes","docs\u002F10.volumes",{"title":83,"path":84,"stem":85},"Key-value store","\u002Fdocs\u002Fredis","docs\u002F11.redis",{"title":87,"path":88,"stem":89},"Workspaces","\u002Fdocs\u002Fworkspaces","docs\u002F12.workspaces",{"title":91,"path":92,"stem":93},"Projects","\u002Fdocs\u002Fprojects","docs\u002F13.projects",{"title":95,"path":96,"stem":97},"Environments","\u002Fdocs\u002Fenvironments","docs\u002F14.environments",{"title":99,"path":100,"stem":101},"Eject","\u002Fdocs\u002Feject","docs\u002F15.eject",{"title":103,"path":104,"stem":105},"API","\u002Fdocs\u002Fapi","docs\u002F16.api",{"title":107,"path":108,"stem":109},"CLI","\u002Fdocs\u002Fcli","docs\u002F17.cli",{"title":111,"path":112,"stem":113},"Claude Plugin & MCP","\u002Fdocs\u002Fclaude-plugin","docs\u002F18.claude-plugin",{"title":115,"path":116,"stem":117},"Metrics","\u002Fdocs\u002Fmetrics","docs\u002F19.metrics",{"title":119,"path":120,"stem":121},"Logs","\u002Fdocs\u002Flogs","docs\u002F20.logs",{"title":123,"path":124,"stem":125},"Billing","\u002Fdocs\u002Fbilling","docs\u002F21.billing",{"title":127,"path":128,"stem":129},"Self-hosting","\u002Fdocs\u002Fself-hosting","docs\u002F22.self-hosting",[131,132,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163],{"title":5,"path":6,"stem":7},{"title":9,"path":10,"stem":11,"children":133},[134,135,136,137,138,139,140,141,142,143],{"title":9,"path":10,"stem":11},{"title":15,"path":16,"stem":17},{"title":19,"path":20,"stem":21},{"title":23,"path":24,"stem":25},{"title":27,"path":28,"stem":29},{"title":31,"path":32,"stem":33},{"title":35,"path":36,"stem":37},{"title":39,"path":40,"stem":41},{"title":43,"path":44,"stem":45},{"title":47,"path":48,"stem":49},{"title":51,"path":52,"stem":53},{"title":55,"path":56,"stem":57},{"title":59,"path":60,"stem":61},{"title":63,"path":64,"stem":65},{"title":67,"path":68,"stem":69},{"title":71,"path":72,"stem":73},{"title":75,"path":76,"stem":77},{"title":79,"path":80,"stem":81},{"title":83,"path":84,"stem":85},{"title":87,"path":88,"stem":89},{"title":91,"path":92,"stem":93},{"title":95,"path":96,"stem":97},{"title":99,"path":100,"stem":101},{"title":103,"path":104,"stem":105},{"title":107,"path":108,"stem":109},{"title":111,"path":112,"stem":113},{"title":115,"path":116,"stem":117},{"title":119,"path":120,"stem":121},{"title":123,"path":124,"stem":125},{"title":127,"path":128,"stem":129},{"id":165,"title":63,"body":166,"description":490,"extension":491,"links":492,"meta":493,"navigation":494,"path":64,"seo":495,"stem":65,"__hash__":496},"docs\u002Fdocs\u002F06.variables.md",{"type":167,"value":168,"toc":480},"minimark",[169,173,181,186,193,212,215,239,243,246,249,255,343,357,360,364,368,371,381,391,395,409,417,420,424,432,444,448],[170,171,172],"p",{},"Variables are how a service is configured without changing its code. Each one is a key and a value, and the service reads them as ordinary environment variables. Which database to connect to, which API to call, which feature to switch on: all of it lives here rather than in the repository.",[170,174,175,176,180],{},"A variable belongs to one service. Development and production are separate services in separate ",[177,178,179],"a",{"href":96},"environments",", so they keep separate variables, which is what lets them point at different databases while running identical code.",[182,183,185],"h2",{"id":184},"service-variables","Service variables",[170,187,188,189,192],{},"Open a service and go to its ",[190,191,63],"strong",{}," tab. Add a key, give it a value, and save.",[170,194,195,196,200,201,204,205,200,208,211],{},"Keys start with a letter or an underscore and continue with letters, digits and underscores. ",[197,198,199],"code",{},"DATABASE_URL"," and ",[197,202,203],{},"_internal"," are fine, ",[197,206,207],{},"2fast",[197,209,210],{},"my-key"," are not.",[170,213,214],{},"Two conveniences worth knowing about:",[216,217,218,233],"ul",{},[219,220,221,224,225,228,229,232],"li",{},[190,222,223],{},"Paste several at once."," Drop ",[197,226,227],{},"KEY=value"," lines straight into a key field and each line becomes its own variable, so moving a ",[197,230,231],{},".env"," file across is one paste rather than twenty.",[219,234,235,238],{},[190,236,237],{},"Values are hidden by default."," Saved values show as dots until you reveal them, individually or all at once, so a variables tab is safe to have open while screensharing.",[182,240,242],{"id":241},"dynamic-variables","Dynamic variables",[170,244,245],{},"Databases, key-value stores and buckets each expose a set of variables, such as their hostname, port and credentials. Any service in the same environment can consume them directly.",[170,247,248],{},"This means you never have to copy sensitive credentials by hand. You pick the one you want from a dropdown in the dashboard instead, and if a database credential is ever rotated, every service consuming it follows along with no changes on your side.",[170,250,251,252,254],{},"To create a dynamic variable, open the service's ",[190,253,63],{}," tab, click the link icon in the value field, and pick from the list. Each resource exposes its own set:",[256,257,258,271],"table",{},[259,260,261],"thead",{},[262,263,264,268],"tr",{},[265,266,267],"th",{},"Resource",[265,269,270],{},"Variables it exposes",[272,273,274,302,319],"tbody",{},[262,275,276,281],{},[277,278,279],"td",{},[177,280,71],{"href":72},[277,282,283,286,287,286,290,286,293,286,296,286,299],{},[197,284,285],{},"fqdn-uri",", ",[197,288,289],{},"host",[197,291,292],{},"port",[197,294,295],{},"dbname",[197,297,298],{},"user",[197,300,301],{},"password",[262,303,304,308],{},[277,305,306],{},[177,307,83],{"href":84},[277,309,310,286,313,286,315,286,317],{},[197,311,312],{},"uri",[197,314,289],{},[197,316,292],{},[197,318,301],{},[262,320,321,326],{},[277,322,323],{},[177,324,325],{"href":76},"Bucket",[277,327,328,286,331,286,334,286,337,286,340],{},[197,329,330],{},"bucket",[197,332,333],{},"endpoint",[197,335,336],{},"region",[197,338,339],{},"accessKeyId",[197,341,342],{},"secretAccessKey",[170,344,345,200,347,349,350,352,353,356],{},[197,346,285],{},[197,348,312],{}," are complete connection strings, which is usually all you need. You can consume one as ",[197,351,199],{}," or ",[197,354,355],{},"REDIS_URL"," and are done. The individual parts are there for libraries that insist on being handed a host and a port separately.",[170,358,359],{},"A service can only consume variables exposed in its own environment. A production service cannot reach into development for a value, which is deliberate.",[361,362,363],"note",{},"A dynamic variable is read when an instance starts, so a rotated credential reaches the service on its next rollout rather than instantly.",[182,365,367],{"id":366},"shared-variables","Shared variables",[170,369,370],{},"Some values belong to a whole environment rather than one service: an API key three services all need, a log level you want to change in one place.",[170,372,373,374,377,378,380],{},"Set those under the project's ",[190,375,376],{},"Settings",", in the ",[190,379,63],{}," section. They belong to the environment you are looking at, so development and production keep separate sets.",[170,382,383,384,386,387,390],{},"A service consumes a shared variable from its own ",[190,385,63],{}," tab, the same way it consumes a dynamic variable. They appear in the picker under ",[190,388,389],{},"Shared",".",[182,392,394],{"id":393},"build-time-and-runtime","Build time and runtime",[170,396,397,398,401,402,352,405,408],{},"Service variables are available while the service ",[177,399,400],{"href":60},"builds"," as well as while it runs, so anything your build reads, such as ",[197,403,404],{},"NEXT_PUBLIC_*",[197,406,407],{},"VITE_*"," values, is there.",[170,410,411,412,416],{},"A value read during the build is baked into the image and stays there until the next build. A value read at runtime is picked up on the next rollout, which ",[177,413,415],{"href":414},"#what-happens-when-you-save","saving a variable"," triggers on its own. Editing a build-time variable therefore needs a rebuild before it takes effect.",[361,418,419],{},"Keep secrets out of build-time variables that end up in the image. Anything inlined into a client-side bundle ships to every visitor, and anything baked into an image layer is readable by anyone who can pull that image. Read secrets at runtime instead.",[182,421,423],{"id":422},"what-happens-when-you-save","What happens when you save",[170,425,426,427,431],{},"Saving variables restarts the service on the image it is already running. The new instance starts with the new values and only takes over once it passes its health check, so the service keeps answering throughout with no downtime. See ",[177,428,430],{"href":429},"\u002Fdocs\u002Fdeployments#rollouts","rollouts"," for how that works, and for the exceptions.",[170,433,434,435,438,439,443],{},"Changing configuration never triggers a build. A new image is only made when you deploy, whether that is a push to the tracked branch, the ",[190,436,437],{},"Deploy"," button in the dashboard, or the CLI. See ",[177,440,442],{"href":441},"\u002Fdocs\u002Fdeployments#configuration-changes","configuration changes"," for everything else that behaves this way.",[182,445,447],{"id":446},"next-steps","Next steps",[216,449,450,455,466,475],{},[219,451,452,454],{},[177,453,51],{"href":52}," for the ports, health checks and resources that variables sit alongside",[219,456,457,286,459,200,462,465],{},[177,458,71],{"href":72},[177,460,461],{"href":84},"key-value stores",[177,463,464],{"href":76},"object storage"," for the resources that expose them",[219,467,468,470,471,474],{},[177,469,59],{"href":60}," for what the builder does with a ",[197,472,473],{},"RAILPACK_"," variable",[219,476,477,479],{},[177,478,55],{"href":56}," for what a rollout actually does",{"title":481,"searchDepth":482,"depth":482,"links":483},"",2,[484,485,486,487,488,489],{"id":184,"depth":482,"text":185},{"id":241,"depth":482,"text":242},{"id":366,"depth":482,"text":367},{"id":393,"depth":482,"text":394},{"id":422,"depth":482,"text":423},{"id":446,"depth":482,"text":447},"Configuration for your services: service variables, shared variables, and dynamic variables.","md",null,{},true,{"title":63,"description":490},"h1gOmM4_RHLlGov3-dzbx7xLsuMlmmqYAD2f1XbihVU",[498,500],{"title":59,"path":60,"stem":61,"description":499,"children":-1},"How Lucity turns your source code into a container image.",{"title":67,"path":68,"stem":69,"description":501,"children":-1},"Put a service on the internet. Use a platform hostname for quick tests, or a domain you own.",[503,506,508,511,514,517,520,523,526,529,532,535,538,540,542,543,544,545,547,549,551,553,555,557,559,561,563,565,567,569,571,573,575,578,582,586],{"path":6,"title":504,"description":505},"Deploy your first service","Deploy an app to Lucity, put it on a public domain, and connect a PostgreSQL database and an object storage bucket in about fifteen minutes.",{"path":507,"title":9,"description":492},"\u002Fdocs\u002Fguides\u002F.navigation",{"path":16,"title":509,"description":510},"Deploy a Next.js app","Deploy a Next.js app on Lucity, with a database, environment variables that behave, and no Dockerfile.",{"path":20,"title":512,"description":513},"Deploy a Nuxt app","Deploy a Nuxt app on Lucity. Nitro output, runtime config, and a database, with no preset to pick.",{"path":24,"title":515,"description":516},"Deploy a SvelteKit app","Deploy a SvelteKit app on Lucity. One adapter change stands between a fresh project and a running service.",{"path":28,"title":518,"description":519},"Deploy an Astro site","Deploy an Astro site on Lucity, static by default and server rendered when you add an adapter.",{"path":32,"title":521,"description":522},"Deploy an Express API","Deploy an Express API on Lucity. Three requirements, none of them platform-specific.",{"path":36,"title":524,"description":525},"Deploy a FastAPI service","Deploy a FastAPI service on Lucity. Detection is picky about layout, and the fix is one setting.",{"path":40,"title":527,"description":528},"Deploy a Django project","Deploy a Django project on Lucity, with migrations that run themselves and static files that do not.",{"path":44,"title":530,"description":531},"Deploy a Laravel application","Deploy a Laravel application on Lucity, with migrations, caches and a queue worker, and no server to configure.",{"path":48,"title":533,"description":534},"Deploy a Go service","Deploy a Go service on Lucity. Compiled in the build, shipped as a binary, nothing else in the image.",{"path":10,"title":536,"description":537},"Deploy your framework","Deploy guides for the frameworks people actually ship: Next.js, Nuxt, SvelteKit, Astro, Express, FastAPI, Django, Laravel, and Go.",{"path":52,"title":51,"description":539},"Services are the deployable units of a project: what they are, how they are configured, and how they scale.",{"path":56,"title":55,"description":541},"How a deployment goes live on Lucity, and the ways to trigger one.",{"path":60,"title":59,"description":499},{"path":64,"title":63,"description":490},{"path":68,"title":67,"description":501},{"path":72,"title":71,"description":546},"Managed PostgreSQL databases, replicated and backed up, connected to your services without copying credentials.",{"path":76,"title":75,"description":548},"S3-compatible buckets for uploads, exports and anything else your service needs to keep.",{"path":80,"title":79,"description":550},"Persistent disks for services that need to keep state on the filesystem.",{"path":84,"title":83,"description":552},"A Redis®-compatible key-value store for caching, sessions and queues.",{"path":88,"title":87,"description":554},"Workspaces represent your organization in Lucity, with their own members, isolation and billing.",{"path":92,"title":91,"description":556},"Projects group services, databases and the environments they run in.",{"path":96,"title":95,"description":558},"Development, staging, production: isolated copies of the same application.",{"path":100,"title":99,"description":560},"Download a project as a Helm chart and run it on a Kubernetes cluster of your own.",{"path":104,"title":103,"description":562},"The GraphQL API behind the dashboard, with an interactive playground.",{"path":108,"title":107,"description":564},"Deploy and manage your services from a terminal or a CI pipeline.",{"path":112,"title":111,"description":566},"Deploy and manage your services from Claude Code, Codex, Cursor or any other MCP client.",{"path":116,"title":115,"description":568},"CPU and memory for every service, and disk usage for every volume.",{"path":120,"title":119,"description":570},"What your services print while they run, and the output of every deployment step.",{"path":124,"title":123,"description":572},"Plans, resource usage, the free trial, and what happens when a payment fails.",{"path":128,"title":127,"description":574},"Run the whole platform on a Kubernetes cluster you own, using the same two Helm charts we run ourselves.",{"path":576,"title":577,"description":492},"\u002Flegal\u002F.navigation","Legal",{"path":579,"title":580,"description":581},"\u002Flegal\u002Fdata-processing-agreement","Data Processing Agreement","How Lucity processes personal data on your behalf.",{"path":583,"title":584,"description":585},"\u002Flegal\u002Fprivacy-policy","Privacy Policy","How Lucity handles your data.",{"path":587,"title":588,"description":589},"\u002Flegal\u002Fterms-of-use","Terms of Use","Terms governing your use of Lucity.",1791216727988]