[{"data":1,"prerenderedAt":366},["ShallowReactive",2],{"navigation":3,"/docs/getting-started/running-from-source":96,"/docs/getting-started/running-from-source-surround":361},[4],{"title":5,"path":6,"stem":7,"children":8,"page":59},"Docs","/docs","docs",[9,25,41,60,80,88],{"title":10,"path":11,"stem":12,"children":13,"icon":24},"Getting Started","/docs/getting-started","docs/1.getting-started/1.index",[14,16,20],{"title":15,"path":11,"stem":12},"Introduction",{"title":17,"path":18,"stem":19},"Quick start","/docs/getting-started/quick-start","docs/1.getting-started/2.quick-start",{"title":21,"path":22,"stem":23},"Running from source","/docs/getting-started/running-from-source","docs/1.getting-started/3.running-from-source","i-lucide-rocket",{"title":26,"path":27,"stem":28,"children":29,"icon":40},"Benchmarks & Methodology","/docs/benchmarks","docs/2.benchmarks/1.index",[30,32,36],{"title":31,"path":27,"stem":28},"Methodology",{"title":33,"path":34,"stem":35},"Reading your results","/docs/benchmarks/reading-your-results","docs/2.benchmarks/2.reading-your-results",{"title":37,"path":38,"stem":39},"Testing from another machine","/docs/benchmarks/testing-from-another-machine","docs/2.benchmarks/3.testing-from-another-machine","i-lucide-flask-conical",{"title":42,"icon":43,"path":44,"stem":45,"children":46,"page":59},"Configuration","i-lucide-settings-2","/docs/configuration","docs/3.configuration",[47,51,55],{"title":48,"path":49,"stem":50},"Adding a real database","/docs/configuration/adding-databases","docs/3.configuration/1.adding-databases",{"title":52,"path":53,"stem":54},"Customizing the image","/docs/configuration/customizing-the-image","docs/3.configuration/2.customizing-the-image",{"title":56,"path":57,"stem":58},"Common tuning strategies","/docs/configuration/common-tuning-strategies","docs/3.configuration/3.common-tuning-strategies",false,{"title":61,"path":62,"stem":63,"children":64,"icon":79},"Image variations","/docs/image-variations","docs/4.image-variations/1.index",[65,67,71,75],{"title":66,"path":62,"stem":63},"Choosing a variation",{"title":68,"path":69,"stem":70},"FPM-NGINX","/docs/image-variations/fpm-nginx","docs/4.image-variations/2.fpm-nginx",{"title":72,"path":73,"stem":74},"FrankenPHP","/docs/image-variations/frankenphp","docs/4.image-variations/3.frankenphp",{"title":76,"path":77,"stem":78},"FPM-Apache","/docs/image-variations/fpm-apache","docs/4.image-variations/4.fpm-apache","i-lucide-layers",{"title":81,"path":82,"stem":83,"children":84,"icon":87},"Community Results","/docs/community-results","docs/5.community-results/1.index",[85],{"title":86,"path":82,"stem":83},"Submitting your results","i-lucide-users",{"title":89,"path":90,"stem":91,"children":92,"icon":95},"FAQ","/docs/faq","docs/6.faq/1.index",[93],{"title":94,"path":90,"stem":91},"Frequently asked questions","i-lucide-circle-help",{"id":97,"title":21,"body":98,"description":354,"extension":355,"links":356,"meta":357,"navigation":159,"path":22,"redirect":356,"seo":358,"sitemap":359,"stem":23,"__hash__":360},"docs/docs/1.getting-started/3.running-from-source.md",{"type":99,"value":100,"toc":349},"minimark",[101,105,112,117,222,233,250,254,257,310,316,322,326,333,345],[102,103,104],"p",{},"Some hosts want your source code rather than a container image. BenchKit runs from source anywhere Laravel runs, including Laravel Cloud and Railway. The hardware stage needs a Linux host that can run fio and download Geekbench; on a managed platform that may not be available, and the other three stages run without it.",[102,106,107,108,111],{},"If your host allows you to run Docker commands (like a VPS), use the ",[109,110,17],"a",{"href":18}," instead. It needs nothing on the machine except Docker, and it is how you compare web servers against each other.",[113,114,116],"h2",{"id":115},"install-it","Install it",[118,119,125],"pre",{"className":120,"code":121,"filename":122,"language":123,"meta":124,"style":124},"language-bash shiki shiki-themes github-dark","git clone https://github.com/serversideup/benchkit-laravel.git\ncd benchkit-laravel\n\ncomposer install --no-dev --optimize-autoloader\nyarn install && yarn build\n\ncp .env.example .env\nphp artisan key:generate\n","Terminal","bash","",[126,127,128,144,154,161,176,193,198,210],"code",{"__ignoreMap":124},[129,130,133,137,141],"span",{"class":131,"line":132},"line",1,[129,134,136],{"class":135},"svObZ","git",[129,138,140],{"class":139},"sU2Wk"," clone",[129,142,143],{"class":139}," https://github.com/serversideup/benchkit-laravel.git\n",[129,145,147,151],{"class":131,"line":146},2,[129,148,150],{"class":149},"sDLfK","cd",[129,152,153],{"class":139}," benchkit-laravel\n",[129,155,157],{"class":131,"line":156},3,[129,158,160],{"emptyLinePlaceholder":159},true,"\n",[129,162,164,167,170,173],{"class":131,"line":163},4,[129,165,166],{"class":135},"composer",[129,168,169],{"class":139}," install",[129,171,172],{"class":149}," --no-dev",[129,174,175],{"class":149}," --optimize-autoloader\n",[129,177,179,182,184,188,190],{"class":131,"line":178},5,[129,180,181],{"class":135},"yarn",[129,183,169],{"class":139},[129,185,187],{"class":186},"s95oV"," && ",[129,189,181],{"class":135},[129,191,192],{"class":139}," build\n",[129,194,196],{"class":131,"line":195},6,[129,197,160],{"emptyLinePlaceholder":159},[129,199,201,204,207],{"class":131,"line":200},7,[129,202,203],{"class":135},"cp",[129,205,206],{"class":139}," .env.example",[129,208,209],{"class":139}," .env\n",[129,211,213,216,219],{"class":131,"line":212},8,[129,214,215],{"class":135},"php",[129,217,218],{"class":139}," artisan",[129,220,221],{"class":139}," key:generate\n",[102,223,224,225,228,229,232],{},"Every benchmark tool BenchKit uses ships as a Composer package, so ",[126,226,227],{},"composer install"," puts them in ",[126,230,231],{},"vendor/bin"," and gives everything you need to run the application.",[234,235,236],"note",{},[102,237,238,241,242,245,246,249],{},[126,239,240],{},".env.example"," is written for local Docker development, so it carries settings you won't need on a server. On a platform that manages environment variables for you, set them there and skip the ",[126,243,244],{},".env"," file. ",[126,247,248],{},"APP_KEY"," is the one value BenchKit cannot start without.",[113,251,253],{"id":252},"deploying-to-a-platform","Deploying to a platform",[102,255,256],{},"Point the platform at the repository and give it a build command that covers both halves of the install:",[118,258,261],{"className":120,"code":259,"filename":260,"language":123,"meta":124,"style":124},"# Install PHP dependencies\ncomposer install --no-dev --optimize-autoloader\n\n# Install Node dependencies\nyarn install\n\n# Build the frontend\nyarn build\n","Build command",[126,262,263,269,279,283,288,295,299,304],{"__ignoreMap":124},[129,264,265],{"class":131,"line":132},[129,266,268],{"class":267},"sAwPA","# Install PHP dependencies\n",[129,270,271,273,275,277],{"class":131,"line":146},[129,272,166],{"class":135},[129,274,169],{"class":139},[129,276,172],{"class":149},[129,278,175],{"class":149},[129,280,281],{"class":131,"line":156},[129,282,160],{"emptyLinePlaceholder":159},[129,284,285],{"class":131,"line":163},[129,286,287],{"class":267},"# Install Node dependencies\n",[129,289,290,292],{"class":131,"line":178},[129,291,181],{"class":135},[129,293,294],{"class":139}," install\n",[129,296,297],{"class":131,"line":195},[129,298,160],{"emptyLinePlaceholder":159},[129,300,301],{"class":131,"line":200},[129,302,303],{"class":267},"# Build the frontend\n",[129,305,306,308],{"class":131,"line":212},[129,307,181],{"class":135},[129,309,192],{"class":139},[102,311,312,313,315],{},"The frontend build matters. Compiled assets are not committed to the repository, so a deploy that only runs ",[126,314,227],{}," will boot and then fail to render. Beyond that, nothing about the deploy is BenchKit-specific.",[317,318,319],"warning",{},[102,320,321],{},"Give BenchKit a host of its own. Running it alongside a production application means the two compete for the same CPU, and neither set of numbers will describe what you think it does.",[113,323,325],{"id":324},"where-your-runs-are-stored","Where your runs are stored",[102,327,328,329,332],{},"Completed runs are written to ",[126,330,331],{},"storage/app/runs"," as JSON files. No database is involved, so there is nothing to migrate and nothing to back up beyond that directory.",[102,334,335,336,344],{},"The local development stack bind-mounts the repository, which keeps your history on your own machine. See ",[109,337,341],{"href":338,"rel":339},"https://github.com/serversideup/benchkit-laravel/blob/main/CONTRIBUTING.md",[340],"nofollow",[126,342,343],{},"CONTRIBUTING.md"," if you are working on BenchKit itself.",[346,347,348],"style",{},"html pre.shiki code .svObZ, html code.shiki .svObZ{--shiki-default:#B392F0}html pre.shiki code .sU2Wk, html code.shiki .sU2Wk{--shiki-default:#9ECBFF}html pre.shiki code .sDLfK, html code.shiki .sDLfK{--shiki-default:#79B8FF}html pre.shiki code .s95oV, html code.shiki .s95oV{--shiki-default:#E1E4E8}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html pre.shiki code .sAwPA, html code.shiki .sAwPA{--shiki-default:#6A737D}",{"title":124,"searchDepth":146,"depth":146,"links":350},[351,352,353],{"id":115,"depth":146,"text":116},{"id":252,"depth":146,"text":253},{"id":324,"depth":146,"text":325},"Run BenchKit on Laravel Cloud, Railway, or any host that wants a repository instead of a container.","md",null,{},{"title":21,"description":354},{"loc":22},"BIA6b-paDu7pAqO3_iV9jp0VzWJJWe__6Bq3IDjtQPY",[362,364],{"title":17,"path":18,"stem":19,"description":363,"children":-1},"Run BenchKit on the server you want to measure.",{"title":31,"path":27,"stem":28,"description":365,"children":-1},"What each stage measures and how a run is put together.",1790284380233]