Changeset 15290
- Timestamp:
- 10/05/2026 09:50:18 PM (2 weeks ago)
- Location:
- sites/trunk/environments
- Files:
-
- 1 added
- 2 edited
-
README.md (modified) (1 diff)
-
freescout/bin/sample-data.php (added)
-
freescout/bin/setup.sh (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/environments/README.md
r15289 r15290 294 294 | `mock-api` | Stands in for `api.wordpress.org/dotorg/freescout/`: checks request signatures, answers sidebar requests with panels recorded from the real endpoints for a real account (`obenland`'s), and logs webhook events (`npm run freescout:logs`). Also stands in for login.wordpress.org's SAML identity provider at http://127.0.0.1:8892/idp, signing with a key that's only for local development. | 295 295 296 `freescout.wordpress.net/Modules/` is mounted as FreeScout's `Modules/` folder, like production's checkout. Every start switches all modules on and runs `freescout:after-app-update`, as production does after a deploy. To try another module, like a premium one, copy it into `freescout.wordpress.net/Modules/` and restart; don't commit it. After switching branches, run `npm run freescout:setup`: FreeScout errors on every page while it still has a removed module cached. 296 `freescout.wordpress.net/Modules/` is mounted as FreeScout's `Modules/` folder, like production's checkout. Every start switches all modules on and runs `freescout:after-app-update`, as production does after a deploy. After switching branches, run `npm run freescout:setup`: FreeScout errors on every page while it still has a removed module cached. 297 298 Setup also adds sample data, set up like the HelpScout helpdesk but with made-up people and conversations. It adds the **Learn WordPress** mailbox, without incoming email. It also adds four made-up agents and 34 made-up conversations in Plugins, Themes and Learn WordPress from the last eight weeks, with replies, notes, and closed, pending, and spam conversations. It only adds what's missing, and only to a FreeScout on 127.0.0.1 or localhost. 299 300 **Premium modules:** to try them, copy them in from a clone of the private [freescout-paid-modules](https://github.com/WordPress/freescout-paid-modules) repository. They must never be committed here, so exclude each one first. From `environments/`: 301 302 ```bash 303 paid=~/path/to/freescout-paid-modules 304 exclude="$(git rev-parse --path-format=absolute --git-common-dir)/info/exclude" 305 for module in "$paid"/Modules/*/; do 306 target="freescout.wordpress.net/Modules/$(basename "$module")" 307 grep -qxF "$target/" "$exclude" || echo "$target/" >> "$exclude" 308 rsync -a --delete "$module" "../$target/" 309 done 310 npm run freescout:setup 311 ``` 312 313 Setup switches them on, and adds sample data for each one that's there, with HelpScout's names: 314 315 - **Tags:** some of HelpScout's tags and colors, on conversations. 316 - **Custom Fields:** the Learn WordPress fields, with values. Plugins and Themes have none. 317 - **Saved Replies:** some of HelpScout's saved replies in Plugins and Themes, with short made-up texts. 318 - **Teams:** the Plugin, Themes and Learn teams, with conversations assigned to some. Names longer than FreeScout's 20 characters are shortened. 319 - **Custom Folders:** "New WordPress" in Plugins, for replies to new WordPress version emails. 320 - **Mentions:** a note in which one agent mentions another. 321 - **Workflows:** some of HelpScout's workflows, with made-up rules. Automatic ones only run for new email with matching subjects, or a tag an agent adds; none run for the sample conversations. 322 - **Reports:** response and resolution times, ready right away. 323 - **API & Webhooks:** a read-only API key for the admin, and a webhook for new conversations to the mock API, which turns it away. 324 325 Slack stays unconfigured: it needs a Slack app. 297 326 298 327 To send more mail in: -
sites/trunk/environments/freescout/bin/setup.sh
r15251 r15290 1 1 #!/usr/bin/env bash 2 2 # 3 # Prepares the local FreeScout: app key, database, admin, mailboxes, modules, and sample email.3 # Prepares the local FreeScout: app key, database, admin, mailboxes, modules, sample data, and sample email. 4 4 # Idempotent; runs inside the app container as www-data on every `npm run freescout:start`. 5 5 … … 60 60 php "$app/artisan" --no-interaction freescout:after-app-update 61 61 62 # After the modules: it adds sample data for premium modules that are copied in. Without it, FreeScout still works. 63 php /srv/env/bin/sample-data.php || echo "Could not add all sample data; run setup again to retry." >&2 64 62 65 # The admin logs in as $WPORG_USERNAME at the mock WordPress.org login; against the mock API, as its "admin". 63 66 username="${WPORG_USERNAME:-}"
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)