Multiple environments in a single render.yaml file
Š
Štefan Ľupták
It would be super useful to be able to do something like this in the
render.yaml
file:environments:
- name: my-project-prod
previewsEnabled: false
services:
# ...
envVarGroups:
# ...
databases:
# ...
- name: my-project-staging
previewsEnabled: true
services:
# ...
envVarGroups:
# ...
databases:
# ...
It's basically "just" nesting the current content of the
render.yaml
file into the environments
array. This would enable workflow such as having prod
without preview environments and then having staging
with preview environments. Workflow like that is currently impossible to achieve when I want to use infrastructure as a code.Log In
k
kolanos
I may be underestimating the complexity here. But I assume Render has "render.yaml" hardcoded somewhere. If we could set our own value for the render.yaml file I think that addresses most of the use cases here. For example when adding a blueprint via the Render console, there could be a field to change the default "render.yaml" value. Then Render just looks for that blueprint file instead of the default "render.yaml" when loading the blueprint. Would also want to do this by environment, so one would add a blueprint for each environment, specifying the blueprint file for each one, or just leaving the default value ("render.yaml") if the user doesn't need an override. This in my mind is the cleanest approach and doesn't require Render to make significant structural changes to the blueprint spec.
But this and related feature requests have been hanging around for years, so it is entirely possible I'm missing something here. Hope we see something like this soon as I think it will simplify a lot of Render setups.
j
james
Yes this would also be incredibly useful for us, either a single file or multiple files, one for each environment, combined with https://feedback.render.com/features/p/disable-individual-services-in-preview-environments
B
Bergur Hallgrimsson
This along with service grouping (https://feedback.render.com/features/p/service-grouping) would be ideal.
Imagine grouping your resources (api, database, redis, static) into a custom group and then defining a blueprint for that e.g.
render.production.yaml
render.staging.yaml
C
Chunlea
Instead of combining all things in a single file, I prefer we have dedicated overwrite yaml file like docker-compose, we can have
render.yaml
as the basic file for default envs, and have render.staging.yaml
or render.production.yaml
to overwrite the old value from the render.yaml
file. One pain I found is that currently the render only support
render.yaml
file, which make me to set up different envs too hard for different team accounts.A
Aldric Giacomoni
Our team would also really like this to be possible.