diff --git a/Taskfile.yml b/Taskfile.yml index 0fca3ec..0e5557e 100644 --- a/Taskfile.yml +++ b/Taskfile.yml @@ -56,6 +56,11 @@ tasks: cmds: - go run ./cmd/api -help + server:build: + desc: Build the Greenlight API server + cmds: + - go build -ldflags '-s' -o ./bin/api ./cmd/api + server:start: desc: Start the Greenlight API server cmds: diff --git a/load_test.sh b/load_test.sh index 3e1aa13..c181ebd 100755 --- a/load_test.sh +++ b/load_test.sh @@ -12,10 +12,10 @@ cleanup() { setup() { # Build the Go binary - go build -o ./bin/server ./cmd/api + go build -o ./bin/api ./cmd/api # Start the web server in the background and discard all output - ./bin/server -limiter-enabled=false > /dev/null & + ./bin/api -limiter-enabled=false > /dev/null & # Capture the PID of the server process so we can kill it later serverPid=$! diff --git a/smoke_test.sh b/smoke_test.sh index c66126a..b74216a 100755 --- a/smoke_test.sh +++ b/smoke_test.sh @@ -9,10 +9,10 @@ cleanup() { } # Build the Go binary -go build -o ./bin/server ./cmd/api +go build -o ./bin/api ./cmd/api # Start the web server in the background -./bin/server & +./bin/api & # Capture the PID of the server process so we can kill it later PID=$!