Skip to content

aleksijohansson/drupal-benchmark

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

886 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Drupal Benchmark

This project is based on the template for Drupal projects by Wunder and meant for benchmarking a local Drupal development environment (either Lando or DDEV) with the open source load testing tool Locust.

View the live results on the Public Dashboard.

See the aforementioned mentioned template for more detailed documentation.

Requirements

Getting started

  • Clone the project locally
  • Optionally checkout a specific version, for example: git checkout tags/v1.0
  • Start your environment (Drupal will be automatically installed)

Benchmark Scripts

This project provides two different benchmark scripts:

benchmark.sh - Local Benchmark Only

Runs a simple benchmark locally without submitting results anywhere. Perfect for quick testing.

./benchmark.sh ddev
# or
./benchmark.sh lando

benchmark-submit.sh - Benchmark with Submission

Runs a benchmark and submits results to the Public Dashboard. This script:

  • Collects system metadata (OS, CPU, memory, versions, etc.)
  • Prompts for computer model and additional comments
  • Submits results automatically
  • Clears cache to refresh the dashboard
./benchmark-submit.sh ddev
# or
lando start && ./benchmark-submit.sh lando

This project comes with Lando and DDEV environments preconfigured. Please find more detailed examples for running the benchmark in these environments below.

Lando

lando start
./benchmark.sh lando          # Local testing only
./benchmark-submit.sh lando   # Submit to dashboard

DDEV

./benchmark.sh ddev           # Local testing only
./benchmark-submit.sh ddev    # Submit to dashboard

Note: Both DDEV and Lando automatically installs Composer dependencies and set up Drupal with existing configuration via post-start hooks. No manual setup required!

Developing frontend

Enable development mode.

By default, benchmark results are sent to the public dashboard. For development, you can enable local mode:

echo "BENCHMARK_ENV=dev" >> .ddev/.env && ddev restart

This will make the benchmark-submit script send data to your local Next.js frontend instead of the public endpoint.

Data is still sent to Supabase, but into a separate dev database.

Install frontend

cd next && ddev npm install

Run frontend

ddev npm run dev

Visit frontend

Visit at: https://frontend.drupal-benchmark.ddev.site/

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Generated from wunderio/drupal-project