Skip to content

Commit

Permalink
Merge branch 'main' into integration-service-location
Browse files Browse the repository at this point in the history
  • Loading branch information
omahane authored Feb 15, 2024
2 parents d80b0f4 + 828acc9 commit f61e3f0
Show file tree
Hide file tree
Showing 31 changed files with 754 additions and 33 deletions.
7 changes: 7 additions & 0 deletions .tugboat/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -226,6 +226,13 @@ services:
- mv "${TUGBOAT_ROOT}/scripts/queue_runner/queue_runner.sh" /etc/service/drupal_events/run
- chmod +x /etc/service/drupal_events/run

# Separate process for next-build preview.
- mkdir -p /etc/service/next_build
- mv "${TUGBOAT_ROOT}/scripts/queue_runner/next_queue_runner.sh" /etc/service/next_build/run
- chmod +x /etc/service/next_build/run
# Need to make build script executable so the runner can run it.
- chmod +x "${TUGBOAT_ROOT}/scripts/next-build-frontend.sh"

clone:
# This j2 command is shared in both the build & clone stages. If modifying, change the other too.
- j2 "${TUGBOAT_ROOT}/.tugboat/.env.j2" -o "${TUGBOAT_ROOT}/.env"
Expand Down
30 changes: 29 additions & 1 deletion READMES/cms-content-release.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,6 @@ sequenceDiagram
Complete->>+Ready: Content release workflow has completed
```


# Environment specific details

## BRD Production
Expand Down Expand Up @@ -144,6 +143,35 @@ The Tugboat and local development versions of the release content page do not tr

For more information on creating or releasing content from a preview environment, see [Environments](./environments.md).

### Next Build Releases

The upcoming static frontend "next-build" can be rebuilt using different versions of next-build and vets-website. It
is a simpler process than the current content-build workflow.

1. Go to "/admin/content/deploy/next".
2. If the form elements are disabled, then a lock file exists preventing another build from being triggered. You
can skip to step #6.
2. Choose a version for next-build or leave at default.
3. Choose a version for vets-website or leave at default. When content-build is releasing, these form fields might
be disabled. We can't change the vets-website version while another frontend build is running.
4. Click "Release Content" to set the versions of next-build and vets-website as well as write a "buildrequest" file.
5. A `scripts/queue_runner/next_queue_runner.sh` script continuously runs in the background looking for the
"buildrequest" file and then start a build if found. Locally, the script has to be triggered manually. See the
[caveats](#caveats) section for more information.
6. Back on "/admin/content/deploy/next" you can view the build log via a link in the "Status" section of the
"Next Build Information" block.
7. Once the build completes no new build will be triggered until you click to release content again.
8. View the frontend at the provided "View Preview" link in the "Next Build Information" block.

#### Caveats

There are some caveats to the process outlined above.

- **Manually running the background script** - On `ddev` the `queue_runner` scripts aren't running continuously in
background jobs. So you must `ddev ssh && ./scripts/queue_runner/` to kick off the content build or next build
release locally. In the future, it might be a good idea to use `system.d` or `supervisor` or something else to
keep the background jobs going locally just like on Tugoboat.

## Troubleshooting

Sometimes the state gets stuck and needs to be reset. It can be done with a drush command
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@
"symfony/phpunit-bridge": "^5.1",
"symfony/process": "^6.3",
"symfony/routing": "^6.3",
"va-gov/content-build": "^0.0.3439",
"va-gov/content-build": "^0.0.3440",
"vlucas/phpdotenv": "^5.3",
"webflo/drupal-finder": "^1.0.0",
"webmozart/path-util": "^2.3",
Expand Down
15 changes: 8 additions & 7 deletions composer.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically"
],
"content-hash": "15c7c7fba07e61d6be8de41d94c2619f",
"content-hash": "3972bf23590490ac39137ab6b269c754",
"packages": [
{
"name": "asm89/stack-cors",
Expand Down Expand Up @@ -25807,16 +25807,16 @@
},
{
"name": "va-gov/content-build",
"version": "v0.0.3439",
"version": "v0.0.3440",
"source": {
"type": "git",
"url": "https://github.com/department-of-veterans-affairs/content-build.git",
"reference": "ef743f09f6c05b78d40bfb01730aac12f3d35988"
"reference": "4ff558516c6af0270ce577b42127f5cd413ddf8f"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/department-of-veterans-affairs/content-build/zipball/ef743f09f6c05b78d40bfb01730aac12f3d35988",
"reference": "ef743f09f6c05b78d40bfb01730aac12f3d35988",
"url": "https://api.github.com/repos/department-of-veterans-affairs/content-build/zipball/4ff558516c6af0270ce577b42127f5cd413ddf8f",
"reference": "4ff558516c6af0270ce577b42127f5cd413ddf8f",
"shasum": ""
},
"type": "node-project",
Expand All @@ -25843,9 +25843,9 @@
"description": "Front-end for VA.gov. This repository contains the code that generates the www.va.gov website. It contains a Metalsmith static site builder that uses a Drupal CMS for content. This file is here to publish releases to https://packagist.org/packages/va-gov/content-build, so that the CMS CI system can install it and update it using standard composer processes, and so that we can run tests across both systems. See https://github.com/department-of-veterans-affairs/va.gov-cms for the CMS repo, and stand by for more documentation.",
"support": {
"issues": "https://github.com/department-of-veterans-affairs/content-build/issues",
"source": "https://github.com/department-of-veterans-affairs/content-build/tree/v0.0.3439"
"source": "https://github.com/department-of-veterans-affairs/content-build/tree/v0.0.3440"
},
"time": "2024-02-08T21:53:11+00:00"
"time": "2024-02-14T14:09:01+00:00"
},
{
"name": "vlucas/phpdotenv",
Expand Down Expand Up @@ -26816,6 +26816,7 @@
"drupal/cer": 10,
"drupal/change_labels": 20,
"drupal/ckeditor_abbreviation": 15,
"drupal/codit_menu_tools": 15,
"drupal/components": 10,
"drupal/danse_content_moderation": 10,
"drupal/entity_block": 10,
Expand Down
4 changes: 2 additions & 2 deletions config/sync/next.next_site.next_build_preview_server.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ status: true
dependencies: { }
id: next_build_preview_server
label: 'Next Build Preview Server'
base_url: 'http://localhost:3000'
preview_url: 'http://localhost:3000/api/preview'
base_url: 'http://localhost:3999'
preview_url: 'http://localhost:3999/api/preview'
preview_secret: secret
revalidate_url: ''
revalidate_secret: ''
13 changes: 13 additions & 0 deletions docroot/modules/custom/va_gov_content_release/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# VA.gov Content Release

va.gov is built using two separate frontend systems with a third being built:

- content-build - This is the frontend for generating static content files. You can read more about the project here:
https://github.com/department-of-veterans-affairs/content-build
- vets-website - This is the frontend for integrating React widgets. You can read more about the project here:
https://github.com/department-of-veterans-affairs/vets-website
- next-build - This is the new frontend for generating static content files. You can read more about the project here:
https://github.com/department-of-veterans-affairs/next-build

More detailed documentation about how these frontends are build and released can be found in the main READMEs
directory on the [CMS Content Release](../../../../READMES/cms-content-release.md) page.
Loading

0 comments on commit f61e3f0

Please sign in to comment.