You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: .controlplane/readme.md
+75-48Lines changed: 75 additions & 48 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,7 +6,7 @@ _If you need a free demo account for Control Plane (no CC required), you can con
6
6
7
7
---
8
8
9
-
Check [how the `cpflow` gem (this project) is used in the Github actions](https://github.com/shakacode/react-webpack-rails-tutorial/blob/master/.github/actions/deploy-to-control-plane/action.yml).
9
+
See the reusable `cpflow-*` GitHub Actions files in this repo's [`.github`](https://github.com/shakacode/react-webpack-rails-tutorial/tree/master/.github) directory for review apps, staging deploys, and production promotion.
10
10
Here is a brief [video overview](https://www.youtube.com/watch?v=llaQoAV_6Iw).
11
11
12
12
---
@@ -69,55 +69,99 @@ You should be able to see this information in the Control Plane UI.
69
69
and not `cpln` which is the Control Plane CLI.
70
70
71
71
```sh
72
-
# Use environment variable to prevent repetition
73
-
export APP_NAME=react-webpack-rails-tutorial
72
+
# Use the staging app defined in .controlplane/controlplane.yml
-`/deploy-review-app` and `/delete-review-app` only run for trusted commenters (`OWNER`, `MEMBER`, `COLLABORATOR`)
162
+
- fork PRs still receive help comments, but review app deploys are skipped because the workflow builds Docker images with repository secrets
163
+
- PR pushes do not auto-create review apps; the first deploy remains opt-in
164
+
121
165
## HTTP/2 and Thruster Configuration
122
166
123
167
This application uses [Thruster](https://github.com/basecamp/thruster), a zero-config HTTP/2 proxy from Basecamp, for optimized performance on Control Plane.
@@ -362,29 +406,12 @@ openssl rand -hex 64
362
406
363
407
## CI Automation, Review Apps and Staging
364
408
365
-
_Note, some of the URL references are internal for the ShakaCode team._
366
-
367
-
Review Apps (deployment of apps based on a PR) are done via Github Actions.
368
-
369
-
The review apps work by creating isolated deployments for each branch through this automated process. When a branch is pushed, the action:
370
-
371
-
1. Sets up the necessary environment and tools
372
-
2. Creates a unique deployment for that branch if it doesn't exist
373
-
3. Builds a Docker image tagged with the branch's commit SHA
374
-
4. Deploys this image to Control Plane with its own isolated environment
375
-
376
-
This allows teams to:
377
-
- Preview changes in a production-like environment
378
-
- Test features independently
379
-
- Share working versions with stakeholders
380
-
- Validate changes before merging to main branches
381
-
382
-
The system uses Control Plane's infrastructure to manage these deployments, with each branch getting its own resources as defined in the controlplane.yml configuration.
383
-
409
+
Review apps, staging deploys, and production promotion are all driven by the
410
+
`cpflow-*` workflows in `.github/workflows/`.
384
411
385
-
### Workflow for Developing Github Actions for Review Apps
412
+
### Workflow for Developing GitHub Actions for Review Apps
386
413
387
-
1. Create a PR with changes to the Github Actions workflow
388
-
2. Make edits to file such as `.github/actions/deploy-to-control-plane/action.yml`
389
-
3.Run a script like `ga .github && gc -m fixes && gp` to commit and push changes (ga = git add, gc = git commit, gp = git push)
390
-
4. Check the Github Actions tab in the PR to see the status of the workflow
414
+
1. Create a PR with changes to the GitHub Actions workflow.
415
+
2. Make edits to files such as `.github/workflows/cpflow-deploy-review-app.yml` or `.github/actions/cpflow-build-docker-image/action.yml`.
416
+
3.Commit and push the `.github`changes.
417
+
4. Check the GitHub Actions tab in the PR to see the status of the workflow.
0 commit comments