mirror of
https://github.com/Skallwar/suckit.git
synced 2026-09-10 07:16:19 -04:00
* tests: Add script to set up local server * tests: Remove old results from speed.csv since test methodology changes * tests: Change speed_regression so it downloads locally hosted webserver * local_server_setup: Remove need of sudo since suckit understands ports * speed_regression: Start local web server in script Co-authored-by: Esteban Blanc <estblcsk@gmail.com>
34 lines
597 B
Bash
Executable file
34 lines
597 B
Bash
Executable file
#!/bin/sh
|
|
|
|
set -e
|
|
|
|
# Create the local's server directory if necessary
|
|
if [[ ! -d local_server ]]; then
|
|
mkdir local_server
|
|
fi
|
|
|
|
cd local_server
|
|
|
|
# Clone repository if necessary
|
|
if [[ ! -d linux ]]; then
|
|
# Clone a big repository
|
|
git clone https://github.com/torvalds/linux
|
|
|
|
cd linux
|
|
|
|
# Checkout the 5.9 release
|
|
git checkout v5.9
|
|
|
|
# No need for the .git directory. It creates a ton of files that take too long
|
|
# to scrape
|
|
rm -rf .git
|
|
|
|
# Get back to local_server
|
|
cd ..
|
|
fi
|
|
|
|
printf "\nWEBSERVER UP\n"
|
|
|
|
# Start up the local python server
|
|
python3 -m http.server
|