cpflow 4.1.0 → 4.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/workflows/claude-code-review.yml +44 -0
- data/.github/workflows/claude.yml +50 -0
- data/.gitignore +6 -0
- data/CHANGELOG.md +17 -1
- data/Gemfile.lock +2 -2
- data/README.md +17 -14
- data/docs/ci-automation.md +28 -0
- data/docs/commands.md +21 -1
- data/docs/terraform/details.md +415 -0
- data/docs/terraform/example/.controlplane/controlplane.yml +29 -0
- data/docs/terraform/example/.controlplane/templates/app.yml +38 -0
- data/docs/terraform/example/.controlplane/templates/postgres.yml +30 -0
- data/docs/terraform/example/.controlplane/templates/rails.yml +26 -0
- data/docs/terraform/overview.md +105 -0
- data/lib/command/base.rb +29 -5
- data/lib/command/base_sub_command.rb +15 -0
- data/lib/command/generate.rb +1 -1
- data/lib/command/ps.rb +1 -1
- data/lib/command/ps_stop.rb +2 -1
- data/lib/command/ps_wait.rb +5 -1
- data/lib/command/run.rb +4 -21
- data/lib/command/terraform/base.rb +35 -0
- data/lib/command/terraform/generate.rb +99 -0
- data/lib/command/terraform/import.rb +79 -0
- data/lib/core/config.rb +1 -1
- data/lib/core/controlplane.rb +7 -6
- data/lib/core/controlplane_api_direct.rb +23 -1
- data/lib/core/shell.rb +9 -4
- data/lib/core/terraform_config/agent.rb +31 -0
- data/lib/core/terraform_config/audit_context.rb +31 -0
- data/lib/core/terraform_config/base.rb +25 -0
- data/lib/core/terraform_config/dsl.rb +102 -0
- data/lib/core/terraform_config/generator.rb +184 -0
- data/lib/core/terraform_config/gvc.rb +63 -0
- data/lib/core/terraform_config/identity.rb +35 -0
- data/lib/core/terraform_config/local_variable.rb +30 -0
- data/lib/core/terraform_config/policy.rb +151 -0
- data/lib/core/terraform_config/provider.rb +22 -0
- data/lib/core/terraform_config/required_provider.rb +23 -0
- data/lib/core/terraform_config/secret.rb +138 -0
- data/lib/core/terraform_config/volume_set.rb +155 -0
- data/lib/core/terraform_config/workload/main.tf +316 -0
- data/lib/core/terraform_config/workload/required_providers.tf +8 -0
- data/lib/core/terraform_config/workload/variables.tf +263 -0
- data/lib/core/terraform_config/workload.rb +132 -0
- data/lib/cpflow/version.rb +1 -1
- data/lib/cpflow.rb +51 -9
- data/lib/generator_templates/templates/postgres.yml +1 -1
- data/lib/patches/array.rb +8 -0
- data/lib/patches/hash.rb +47 -0
- data/lib/patches/string.rb +34 -0
- data/script/update_command_docs +6 -2
- metadata +37 -4
- /data/docs/{migrating.md → migrating-heroku-to-control-plane.md} +0 -0
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: dc6063b9255b39b0e28fba089bec5fd9ac88d05db3902c4f3f79d89afa6c38f0
|
|
4
|
+
data.tar.gz: febd4388547d3ed2a25ca0f9c8231d704891f26457c2860bb3586bf9ad75f745
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: ef1a7b52cfd4166056d66e5997b497bee2dadfbaf31185ef276ac5c030937acae95866400edcfe43fece6c9304d5865a811a615632f25f0586b0cf08ced74be9
|
|
7
|
+
data.tar.gz: 0fe9f702f59c555935d21fbb2fd9eec3285c99ed3f915414ffafa40330e4cc9066a122f577098e7e4f2f162146775c607db516c137464986983dcfbda7318272
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
name: Claude Code Review
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
pull_request:
|
|
5
|
+
types: [opened, synchronize, ready_for_review, reopened]
|
|
6
|
+
|
|
7
|
+
jobs:
|
|
8
|
+
claude-review:
|
|
9
|
+
runs-on: ubuntu-latest
|
|
10
|
+
permissions:
|
|
11
|
+
contents: read
|
|
12
|
+
pull-requests: write
|
|
13
|
+
issues: write
|
|
14
|
+
id-token: write
|
|
15
|
+
|
|
16
|
+
steps:
|
|
17
|
+
- name: Checkout repository
|
|
18
|
+
uses: actions/checkout@v6
|
|
19
|
+
with:
|
|
20
|
+
fetch-depth: 1
|
|
21
|
+
|
|
22
|
+
- name: Run Claude Code Review
|
|
23
|
+
id: claude-review
|
|
24
|
+
uses: anthropics/claude-code-action@v1
|
|
25
|
+
with:
|
|
26
|
+
claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}
|
|
27
|
+
prompt: |
|
|
28
|
+
REPO: ${{ github.repository }}
|
|
29
|
+
PR NUMBER: ${{ github.event.pull_request.number }}
|
|
30
|
+
|
|
31
|
+
Please review this pull request with a focus on:
|
|
32
|
+
- Code quality and best practices
|
|
33
|
+
- Potential bugs or issues
|
|
34
|
+
- Security implications
|
|
35
|
+
- Performance considerations
|
|
36
|
+
|
|
37
|
+
Note: The PR branch is already checked out in the current working directory.
|
|
38
|
+
|
|
39
|
+
Use `gh pr comment` for top-level feedback.
|
|
40
|
+
Use `mcp__github_inline_comment__create_inline_comment` to highlight specific code issues.
|
|
41
|
+
Only post GitHub comments - don't submit review text as messages.
|
|
42
|
+
|
|
43
|
+
claude_args: |
|
|
44
|
+
--allowedTools "mcp__github_inline_comment__create_inline_comment,Bash(gh pr comment:*),Bash(gh pr diff:*),Bash(gh pr view:*)"
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
name: Claude Code
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
issue_comment:
|
|
5
|
+
types: [created]
|
|
6
|
+
pull_request_review_comment:
|
|
7
|
+
types: [created]
|
|
8
|
+
issues:
|
|
9
|
+
types: [opened, assigned]
|
|
10
|
+
pull_request_review:
|
|
11
|
+
types: [submitted]
|
|
12
|
+
|
|
13
|
+
jobs:
|
|
14
|
+
claude:
|
|
15
|
+
if: |
|
|
16
|
+
(github.event_name == 'issue_comment' && contains(github.event.comment.body, '@claude')) ||
|
|
17
|
+
(github.event_name == 'pull_request_review_comment' && contains(github.event.comment.body, '@claude')) ||
|
|
18
|
+
(github.event_name == 'pull_request_review' && contains(github.event.review.body, '@claude')) ||
|
|
19
|
+
(github.event_name == 'issues' && (contains(github.event.issue.body, '@claude') || contains(github.event.issue.title, '@claude')))
|
|
20
|
+
runs-on: ubuntu-latest
|
|
21
|
+
permissions:
|
|
22
|
+
contents: read
|
|
23
|
+
pull-requests: read
|
|
24
|
+
issues: read
|
|
25
|
+
id-token: write
|
|
26
|
+
actions: read # Required for Claude to read CI results on PRs
|
|
27
|
+
steps:
|
|
28
|
+
- name: Checkout repository
|
|
29
|
+
uses: actions/checkout@v4
|
|
30
|
+
with:
|
|
31
|
+
fetch-depth: 1
|
|
32
|
+
|
|
33
|
+
- name: Run Claude Code
|
|
34
|
+
id: claude
|
|
35
|
+
uses: anthropics/claude-code-action@v1
|
|
36
|
+
with:
|
|
37
|
+
claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}
|
|
38
|
+
|
|
39
|
+
# This is an optional setting that allows Claude to read CI results on PRs
|
|
40
|
+
additional_permissions: |
|
|
41
|
+
actions: read
|
|
42
|
+
|
|
43
|
+
# Optional: Give a custom prompt to Claude. If this is not specified, Claude will perform the instructions specified in the comment that tagged it.
|
|
44
|
+
# prompt: 'Update the pull request description to include a summary of changes.'
|
|
45
|
+
|
|
46
|
+
# Optional: Add claude_args to customize behavior and configuration
|
|
47
|
+
# See https://github.com/anthropics/claude-code-action/blob/main/docs/usage.md
|
|
48
|
+
# or https://code.claude.com/docs/en/cli-reference for available options
|
|
49
|
+
# claude_args: '--allowed-tools Bash(gh pr:*)'
|
|
50
|
+
|
data/.gitignore
CHANGED
data/CHANGELOG.md
CHANGED
|
@@ -14,6 +14,21 @@ Changes since the last non-beta release.
|
|
|
14
14
|
|
|
15
15
|
_Please add entries here for your pull requests that have not yet been released._
|
|
16
16
|
|
|
17
|
+
### Fixed
|
|
18
|
+
|
|
19
|
+
- Fixed issue where `run` command could hang indefinitely when updating runner workload. [PR 260](https://github.com/shakacode/control-plane-flow/pull/260) by [Sergey Tarasov](https://github.com/dzirtusss).
|
|
20
|
+
|
|
21
|
+
### Changed
|
|
22
|
+
|
|
23
|
+
- Redact sensitive data (Authorization headers, tokens) from `--trace` output. [PR 261](https://github.com/shakacode/control-plane-flow/pull/261) by [Sergey Tarasov](https://github.com/dzirtusss).
|
|
24
|
+
|
|
25
|
+
## [4.1.1] - 2025-03-14
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
### Fixed
|
|
29
|
+
|
|
30
|
+
- Fixed issue where `ps`, `ps:start`, `ps:stop`, `ps:wait`, and `run` commands fail when trying to fetch replicas with CPLN CLI. [PR 254](https://github.com/shakacode/control-plane-flow/pull/254) by [Rafael Gomes](https://github.com/rafaelgomesxyz).
|
|
31
|
+
|
|
17
32
|
## [4.1.0] - 2024-12-17
|
|
18
33
|
|
|
19
34
|
### Fixed
|
|
@@ -276,7 +291,8 @@ Deprecated `cpl` gem. New gem is `cpflow`.
|
|
|
276
291
|
|
|
277
292
|
First release.
|
|
278
293
|
|
|
279
|
-
[Unreleased]: https://github.com/shakacode/control-plane-flow/compare/v4.1.
|
|
294
|
+
[Unreleased]: https://github.com/shakacode/control-plane-flow/compare/v4.1.1...HEAD
|
|
295
|
+
[4.1.1]: https://github.com/shakacode/control-plane-flow/compare/v4.1.0...v4.1.1
|
|
280
296
|
[4.1.0]: https://github.com/shakacode/control-plane-flow/compare/v4.0.0...v4.1.0
|
|
281
297
|
[4.0.0]: https://github.com/shakacode/control-plane-flow/compare/v3.0.1...v4.0.0
|
|
282
298
|
[3.0.1]: https://github.com/shakacode/control-plane-flow/compare/v3.0.0...v3.0.1
|
data/Gemfile.lock
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
PATH
|
|
2
2
|
remote: .
|
|
3
3
|
specs:
|
|
4
|
-
cpflow (4.
|
|
4
|
+
cpflow (4.2.0)
|
|
5
5
|
dotenv (~> 2.8.1)
|
|
6
6
|
jwt (~> 2.8.1)
|
|
7
7
|
psych (~> 5.1.0)
|
|
@@ -13,7 +13,7 @@ GEM
|
|
|
13
13
|
addressable (2.8.7)
|
|
14
14
|
public_suffix (>= 2.0.2, < 7.0)
|
|
15
15
|
ast (2.4.2)
|
|
16
|
-
base64 (0.
|
|
16
|
+
base64 (0.3.0)
|
|
17
17
|
bigdecimal (3.1.8)
|
|
18
18
|
childprocess (4.1.0)
|
|
19
19
|
crack (1.0.0)
|
data/README.md
CHANGED
|
@@ -37,7 +37,7 @@ many "Heroku" abstractions and naming conventions.
|
|
|
37
37
|
|
|
38
38
|
Control Plane provides access to raw cloud computing power but lacks the simple abstractions of Heroku. The `cpflow` CLI bridges this gap, delivering a streamlined and familiar experience for developers.
|
|
39
39
|
|
|
40
|
-
While this repository simplifies migration from Heroku, the `cpflow` CLI is versatile and can be used for
|
|
40
|
+
While this repository simplifies migration from Heroku, the `cpflow` CLI is versatile and can be used for any application. This document contains **concept mapping** and **helper CLI** approach to streamline deployment workflows and minimize manual effort.
|
|
41
41
|
|
|
42
42
|
Additionally, the documentation includes numerous examples and practical tips for teams transitioning from Heroku to Kubernetes, helping them make the most of Control Plane's advanced features.
|
|
43
43
|
|
|
@@ -54,9 +54,9 @@ Additionally, the documentation includes numerous examples and practical tips fo
|
|
|
54
54
|
11. [CLI Commands Reference](#cli-commands-reference)
|
|
55
55
|
12. [Mapping of Heroku Commands to `cpflow` and `cpln`](#mapping-of-heroku-commands-to-cpflow-and-cpln)
|
|
56
56
|
13. [Examples](#examples)
|
|
57
|
-
14. [Migrating Postgres Database from Heroku Infrastructure](/docs/postgres
|
|
58
|
-
15. [Migrating Redis Database from Heroku Infrastructure](/docs/redis
|
|
59
|
-
16. [Tips](/docs/tips
|
|
57
|
+
14. [Migrating Postgres Database from Heroku Infrastructure](https://www.shakacode.com/control-plane-flow/docs/postgres/)
|
|
58
|
+
15. [Migrating Redis Database from Heroku Infrastructure](https://www.shakacode.com/control-plane-flow/docs/redis/)
|
|
59
|
+
16. [Tips](https://www.shakacode.com/control-plane-flow/docs/tips/)
|
|
60
60
|
|
|
61
61
|
## Key Features
|
|
62
62
|
|
|
@@ -82,7 +82,7 @@ On Control Plane, we can map a Heroku app to a GVC (Global Virtual Cloud). Such
|
|
|
82
82
|
be anything that can run as a container.
|
|
83
83
|
|
|
84
84
|
| Heroku | Control Plane |
|
|
85
|
-
|
|
85
|
+
|------------------|---------------------------------------------|
|
|
86
86
|
| _app_ | _GVC_ (Global Virtual Cloud) |
|
|
87
87
|
| _dyno_ | _workload_ |
|
|
88
88
|
| _add-on_ | either a _workload_ or an external resource |
|
|
@@ -105,7 +105,12 @@ For the typical Rails app, this means:
|
|
|
105
105
|
| in-memory db | `redis`, `memcached` | add-on | external provider or can be set up for development/testing with Docker image (lacks persistence between restarts) |
|
|
106
106
|
| others | `mailtrap` | add-on | external provider or can be set up for development/testing with Docker image (lacks persistence between restarts) |
|
|
107
107
|
|
|
108
|
-
##
|
|
108
|
+
## Migration Strategy
|
|
109
|
+
See this doc for [detailed migration steps](./docs/migrating-heroku-to-control-plane.md) from Heroku to Control Plane. Even if you are coming from a platform other than Heroku, you can still benefit from the migration steps.
|
|
110
|
+
|
|
111
|
+
## System Prerequisites
|
|
112
|
+
|
|
113
|
+
_Note, if you want to use Terraform with cpflow, you will start the same way below._
|
|
109
114
|
|
|
110
115
|
1. Ensure your [Control Plane](https://shakacode.controlplane.com/) account is set up. Set up an `organization` `<your-org>` for testing in that account and modify the value for `aliases.common.cpln_org` in `.controlplane/controlplane.yml`, or you can also set it with the `CPLN_ORG` environment variable. If you need an organization, please [contact Shakacode](mailto:controlplane@shakacode.com).
|
|
111
116
|
|
|
@@ -130,15 +135,11 @@ npm update -g @controlplane/cli
|
|
|
130
135
|
|
|
131
136
|
6. Install Control Plane Flow `cpflow` CLI as a [Ruby gem](https://rubygems.org/gems/cpflow): `gem install cpflow`. If you want to use `cpflow` from Rake tasks in a Rails project, use `Bundler.with_unbundled_env { `cpflow help` } or else you'll get an error that `cpflow` cannot be found. While you can add `cpflow` to your Gemfile, it's not recommended because it might trigger conflicts with other gems.
|
|
132
137
|
|
|
133
|
-
7. You can use [this Dockerfile](https://github.com/shakacode/
|
|
138
|
+
7. You will need a production-ready Dockerfile. If you're using Rails, consider the default one that ships with Rails 8. You can use [this Dockerfile](https://github.com/shakacode/rails-v8-kamal-v2-terraform-gcp-tutorial/blob/master/Dockerfile) as an example for your project. Ensure that you have Docker running.
|
|
134
139
|
|
|
135
140
|
**Note:** Do not confuse the `cpflow` CLI with the `cpln` CLI. The `cpflow` CLI is the Control Plane Flow playbook CLI.
|
|
136
141
|
The `cpln` CLI is the Control Plane CLI.
|
|
137
142
|
|
|
138
|
-
## Steps to Migrate
|
|
139
|
-
|
|
140
|
-
Click [here](/docs/migrating.md) to see the steps to migrate.
|
|
141
|
-
|
|
142
143
|
## Configuration Files
|
|
143
144
|
|
|
144
145
|
The `cpflow` gem is based on several configuration files within a `/.controlplane` top-level directory in your project.
|
|
@@ -331,6 +332,8 @@ apps:
|
|
|
331
332
|
|
|
332
333
|
For a live example, see the [react-webpack-rails-tutorial](https://github.com/shakacode/react-webpack-rails-tutorial/blob/master/.controlplane/readme.md) repository.
|
|
333
334
|
|
|
335
|
+
You can use this repository as a reference for setting up your own project.
|
|
336
|
+
|
|
334
337
|
This example should closely match the below example.
|
|
335
338
|
|
|
336
339
|
Suppose your app is called `tutorial-app`. You can run the following commands.
|
|
@@ -479,7 +482,7 @@ development purposes.
|
|
|
479
482
|
|
|
480
483
|
## Scheduled Jobs
|
|
481
484
|
|
|
482
|
-
Control Plane supports scheduled jobs via [cron workloads](https://shakadocs.controlplane.com/reference/workload#cron).
|
|
485
|
+
Control Plane supports scheduled jobs via [cron workloads](https://shakadocs.controlplane.com/reference/workload/types#cron).
|
|
483
486
|
|
|
484
487
|
Here's a partial example of a template for a cron workload, using the app image:
|
|
485
488
|
|
|
@@ -503,7 +506,7 @@ spec:
|
|
|
503
506
|
image: "/org/APP_ORG/image/APP_IMAGE"
|
|
504
507
|
```
|
|
505
508
|
|
|
506
|
-
A complete example can be found at [templates/daily-task.yml](templates/daily-task.yml), optimized for Control Plane and
|
|
509
|
+
A complete example can be found at [templates/daily-task.yml](https://github.com/shakacode/control-plane-flow/blob/main/templates/daily-task.yml), optimized for Control Plane and
|
|
507
510
|
suitable for development purposes.
|
|
508
511
|
|
|
509
512
|
You can create the cron workload by adding the template for it to the `.controlplane/templates/` directory and running
|
|
@@ -513,7 +516,7 @@ Then to view the logs of the cron workload, you can run `cpflow logs -a my-app -
|
|
|
513
516
|
|
|
514
517
|
## CLI Commands Reference
|
|
515
518
|
|
|
516
|
-
Click [here](/docs/commands
|
|
519
|
+
Click [here](https://www.shakacode.com/control-plane-flow/docs/commands/) to see the commands.
|
|
517
520
|
|
|
518
521
|
You can also run the following command:
|
|
519
522
|
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
# CI Automation, Review Apps, Staging, and Promoting to Production
|
|
2
|
+
|
|
3
|
+
## Setting up Tokens for CI Automation
|
|
4
|
+
|
|
5
|
+
This example uses Github Actions. The same applies to Circle CI and other similar CI/CD tools.
|
|
6
|
+
|
|
7
|
+
1. Ensure that you have two orgs:
|
|
8
|
+
1. `company-staging` (for staging deployments, developers have access)
|
|
9
|
+
2. `company-production` (for production deployments, limited access)
|
|
10
|
+
2. Create the token for staging org and set on Github repository secrets and variables:
|
|
11
|
+
1. Go to the Control Plane UI for your organization's staging org
|
|
12
|
+
2. Make a new service account called `github-actions-staging`
|
|
13
|
+
3. Assign to the group `superusers`
|
|
14
|
+
4. Click "Keys" and create a one with description "Github Actions" and copy the token (or download it).
|
|
15
|
+
5. Add this key to your Github repository **secrets** as `CPLN_TOKEN_STAGING`
|
|
16
|
+
6. Add another key to your Github repository **variables** as `CPLN_ORG_STAGING` with the name of the staging org, like `company-staging`
|
|
17
|
+
3. Create the token for production org, and set on Github repository secrets and variables.
|
|
18
|
+
1. Go to the Control Plane UI for your organization's production org
|
|
19
|
+
2. Make a new service account called `github-actions-production`
|
|
20
|
+
3. Assign to the group `superusers`
|
|
21
|
+
4. Click "Keys" and create a one with description "Github Actions" and copy the token (or download it).
|
|
22
|
+
5. Add this key to your Github repository **secrets** as `CPLN_TOKEN_PRODUCTION`
|
|
23
|
+
6. Add another key to your Github repository **variables** as `CPLN_ORG_PRODUCTION` with the name of the production org, like `company-production`
|
|
24
|
+
4. Create a few more ENV **variables** for the app name and the app prefix:
|
|
25
|
+
1. `STAGING_APP_NAME` - the name of the app in Control Plane for staging, which is the GVC name, like `app-name-staging`
|
|
26
|
+
2. `PRODUCTION_APP_NAME` - the name of the app in Control Plane for production, which is the GVC name, like `app-name-production`
|
|
27
|
+
3. `REVIEW_APP_PREFIX` - the prefix for the review apps in Control Plane. The Review apps are named `$REVIEW_APP_PREFIX-pr-$PR_NUMBER`
|
|
28
|
+
5. All in all, you should have 2 secrets and 5 variables set in your Github repository
|
data/docs/commands.md
CHANGED
|
@@ -354,13 +354,17 @@ cpflow ps:stop -a $APP_NAME -w $WORKLOAD_NAME -r $REPLICA_NAME
|
|
|
354
354
|
### `ps:wait`
|
|
355
355
|
|
|
356
356
|
- Waits for workloads in app to be ready after re-deployment
|
|
357
|
+
- Use Unix timeout command to set a maximum wait time (e.g., `timeout 300 cpflow ps:wait ...`)
|
|
357
358
|
|
|
358
359
|
```sh
|
|
359
360
|
# Waits for all workloads in app.
|
|
360
361
|
cpflow ps:wait -a $APP_NAME
|
|
361
362
|
|
|
362
363
|
# Waits for a specific workload in app.
|
|
363
|
-
cpflow ps:
|
|
364
|
+
cpflow ps:wait -a $APP_NAME -w $WORKLOAD_NAME
|
|
365
|
+
|
|
366
|
+
# Waits for all workloads with a 5-minute timeout.
|
|
367
|
+
timeout 300 cpflow ps:wait -a $APP_NAME
|
|
364
368
|
```
|
|
365
369
|
|
|
366
370
|
### `run`
|
|
@@ -444,6 +448,22 @@ cpflow run -a $APP_NAME --entrypoint /app/alternative-entrypoint.sh -- rails db:
|
|
|
444
448
|
cpflow setup-app -a $APP_NAME
|
|
445
449
|
```
|
|
446
450
|
|
|
451
|
+
### `terraform generate`
|
|
452
|
+
|
|
453
|
+
- Generates terraform configuration files based on `controlplane.yml` and `templates/` config
|
|
454
|
+
|
|
455
|
+
```sh
|
|
456
|
+
cpflow terraform generate
|
|
457
|
+
```
|
|
458
|
+
|
|
459
|
+
### `terraform import`
|
|
460
|
+
|
|
461
|
+
- Imports terraform resources from the generated configuration files
|
|
462
|
+
|
|
463
|
+
```sh
|
|
464
|
+
cpflow terraform import
|
|
465
|
+
```
|
|
466
|
+
|
|
447
467
|
### `version`
|
|
448
468
|
|
|
449
469
|
- Displays the current version of the CLI
|