From 86f036d8cc33ce20b17372b68191a244348f7da4 Mon Sep 17 00:00:00 2001 From: Arthur Khachaturov Date: Fri, 26 Jul 2024 15:40:30 +0300 Subject: [PATCH] chore: minor edits --- Dockerfile | 2 +- README.md | 23 ----------------------- src/request.sh | 1 + 3 files changed, 2 insertions(+), 24 deletions(-) diff --git a/Dockerfile b/Dockerfile index 13e1aff..d92a037 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,5 +1,5 @@ FROM debian:stable-slim -RUN apt-get update && apt-get install socat file -y +RUN apt-get update && apt-get install socat file pandoc -y ENV HTTB_LIB_PATH="/usr/lib/httb" WORKDIR ${HTTB_LIB_PATH} COPY src/ . diff --git a/README.md b/README.md index 67f0a58..8880837 100644 --- a/README.md +++ b/README.md @@ -31,29 +31,6 @@ To get started with Docker: # Add your additional setup steps here, if needed ``` -4. **Run the Docker container using `docker-compose`**: - ```sh - docker-compose up --build - ``` - -### Example `docker-compose.yml` -Here is an example `docker-compose.yml` file to help you get started: - -```yaml -version: '3.8' - -services: - httb: - image: httb:latest - build: - context: . - dockerfile: Dockerfile - ports: - - "8080:8080" -``` - -With these steps and files, you should be able to set up and run your httb server in a Docker container. - ## 🖥️ Native If you prefer to run httb natively on your system, ensure you have `bash socat file` installed. These tools are necessary for running this server. diff --git a/src/request.sh b/src/request.sh index 4a38ee3..476f549 100644 --- a/src/request.sh +++ b/src/request.sh @@ -23,6 +23,7 @@ http::_route_request() { for glob_endpoint in "${!http__all_routes[@]}"; do # FIXME O(n) # shellcheck disable=SC2053 if [[ "${request_path}" == ${glob_endpoint} ]]; then + declare -rx HTTP_REQUEST_GLOB="${glob_endpoint}" path_found=1 break fi