|
1 | 1 | ---
|
2 | 2 | title: Ephemeral Environments
|
3 |
| -description: Ephemeral Environments are a way to create and destroy environments on demand. |
| 3 | +description: Create and destroy isolated testing environments automatically based on pull requests or other triggers to optimize your development workflow. |
4 | 4 | ---
|
5 | 5 |
|
6 |
| -## Determining if you need an ephemeral environment |
| 6 | +## Is Ephemeral Environments Right for Your Team? |
7 | 7 |
|
8 |
| -Here are some key questions to help determine if ephemeral environments would benefit your workflow: |
| 8 | +Consider these key questions to determine if ephemeral environments would benefit your workflow: |
9 | 9 |
|
10 | 10 | <AccordionGroup>
|
11 | 11 | <Accordion title="Do you need isolated testing environments?">
|
12 |
| - If your team needs to test features in isolation without impacting other developers or staging environments, ephemeral environments allow you to spin up dedicated environments on-demand. |
| 12 | + Ephemeral environments provide isolated testing spaces for each feature or branch, preventing conflicts between developers and ensuring clean test conditions for every change. |
13 | 13 | </Accordion>
|
14 | 14 |
|
15 |
| -<Accordion title="Are your environments complex to set up?"> |
16 |
| - When environments require multiple services, databases, and configurations to |
17 |
| - be set up, ephemeral environments can automate this process and ensure |
18 |
| - consistency. |
19 |
| -</Accordion> |
20 |
| - |
21 |
| -<Accordion title="Do you have high infrastructure costs?"> |
22 |
| - If maintaining multiple long-running environments is costly, ephemeral |
23 |
| - environments can help reduce costs by only running when needed and |
24 |
| - automatically cleaning up unused resources. |
25 |
| -</Accordion> |
26 |
| - |
27 |
| -<Accordion title="Do you need to test branch-specific changes?"> |
28 |
| - Ephemeral environments make it easy to test changes from specific branches by |
29 |
| - creating isolated environments that match your branch configuration. |
30 |
| -</Accordion> |
31 |
| - |
32 |
| - <Accordion title="Is your team growing?"> As teams scale, coordinating |
33 |
| - environment usage becomes more challenging. Ephemeral environments give each |
34 |
| - developer or team their own space to work without interference. </Accordion> |
| 15 | + <Accordion title="Are your environments complex to set up?"> |
| 16 | + When environments require multiple services, databases, and configurations, ephemeral environments automate this complex process, ensuring consistent setups every time and saving hours of manual configuration. |
| 17 | + </Accordion> |
| 18 | + |
| 19 | + <Accordion title="Do you have high infrastructure costs?"> |
| 20 | + By automatically creating environments when needed and destroying them when work is complete, ephemeral environments can significantly reduce cloud infrastructure costs compared to maintaining multiple permanent environments. |
| 21 | + </Accordion> |
| 22 | + |
| 23 | + <Accordion title="Do you need to test branch-specific changes?"> |
| 24 | + Ephemeral environments create isolated testing spaces that exactly match your branch configuration, making it easy to validate changes in context before merging to the main codebase. |
| 25 | + </Accordion> |
| 26 | + |
| 27 | + <Accordion title="Is your team growing?"> |
| 28 | + As teams scale, coordinating environment usage becomes increasingly challenging. Ephemeral environments eliminate contention by giving each developer or team their own dedicated space to work without interference. |
| 29 | + </Accordion> |
35 | 30 | </AccordionGroup>
|
36 | 31 |
|
37 |
| -If you answered yes to any of these questions, implementing ephemeral |
38 |
| -environments could significantly improve your development workflow. |
| 32 | +If you answered yes to any of these questions, implementing ephemeral environments with Ctrlplane could significantly improve your development workflow and reduce operational overhead. |
39 | 33 |
|
40 | 34 | ## Scenario
|
41 | 35 |
|
@@ -70,18 +64,15 @@ graph TD
|
70 | 64 |
|
71 | 65 | ## 1. Pull Request Resource Creation
|
72 | 66 |
|
73 |
| -When using Ctrlplane for any system, you must first determine what resources |
74 |
| -represent the the existance of your deployment. |
| 67 | +When using Ctrlplane for any system, you must first determine what resources represent the existence of your deployment. |
75 | 68 |
|
76 |
| -In this case, we will use the GitHub pull request to determine if the ephemeral |
77 |
| -environment should be created and when it should be destroyed. |
| 69 | +In this case, we'll use GitHub pull requests to determine when ephemeral environments should be created and destroyed. |
78 | 70 |
|
79 |
| -This means Ctrlplane will follow the lifecycle of the pull request - creating |
80 |
| -the environment when the PR is opened and destroying it when the PR is merged or |
81 |
| -closed. |
| 71 | +This approach means Ctrlplane will follow the PR lifecycle: |
| 72 | +- Creating the environment when a PR is opened |
| 73 | +- Destroying it when the PR is merged or closed |
82 | 74 |
|
83 |
| -todo this we will need to create a Github that tracks and updates resources in |
84 |
| -ctrlplane as pull requests state changes. |
| 75 | +To implement this workflow, we'll create a GitHub workflow that tracks PR state changes and updates resources in Ctrlplane accordingly. |
85 | 76 |
|
86 | 77 | Here is what it does:
|
87 | 78 |
|
|
0 commit comments