diff --git a/.gitignore b/.gitignore index cf3979d..3bb4027 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1 @@ -/httpd +/playground diff --git a/Dockerfile b/Dockerfile index f6eb1f8..eaa162b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -28,7 +28,7 @@ RUN git clone https://git.sr.ht/~sircmpwn/hare && \ WORKDIR /src COPY ./ ./ -RUN make -B httpd HAREPATH=/usr/local/src/hare/stdlib HAREFLAGS=-lpthread +RUN make -B playground HAREPATH=/usr/local/src/hare/stdlib HAREFLAGS=-lpthread FROM ubuntu:24.04 @@ -41,8 +41,8 @@ RUN apt-get update -qq \ vim COPY --from=harebuild /usr/local /usr/local -COPY --from=harebuild /src/httpd /usr/local/bin/backend +COPY --from=harebuild /src/playground /usr/local/bin/playground COPY ./frontend/ /app/ WORKDIR /app -ENTRYPOINT ["/usr/local/bin/backend", "-a", "0.0.0.0:8080"] +ENTRYPOINT ["/usr/local/bin/playground", "-a", "0.0.0.0:8080"] diff --git a/Makefile b/Makefile index d1f829c..aca2f87 100644 --- a/Makefile +++ b/Makefile @@ -15,9 +15,9 @@ classpathify = $(subst $(eval ) ,:,$1) HAREEXTRAPATH = $(HAREPATH) HAREEXTRAPATH += $(wildcard vendor/*) -all: httpd +all: playground -httpd: $(wildcard cmd/httpd/*.ha) $(SOURCES) +playground: $(wildcard cmd/playground/*.ha) $(SOURCES) HAREPATH=$(call classpathify,$(HAREEXTRAPATH)) \ $(HARE) build $(HAREFLAGS) -o $@ cmd/$@/ @@ -26,15 +26,15 @@ check: $(HARE) test $(HAREFLAGS) clean: - rm -f httpd + rm -f playground -install: httpd - install -Dm755 web $(DESTDIR)$(BINDIR)/httpd +install: playground + install -Dm755 web $(DESTDIR)$(BINDIR)/playground uninstall: - rm -f $(DESTDIR)$(BINDIR)/httpd + rm -f $(DESTDIR)$(BINDIR)/playground -test: httpd +test: playground hurl --test test/api.hurl .PHONY: all check clean install uninstall test diff --git a/README.md b/README.md index c3f1454..7a55067 100644 --- a/README.md +++ b/README.md @@ -26,7 +26,7 @@ docker build -t hareplayground ## Run locally ``` -./httpd -b ./frontend +./playground -b ./frontend ``` ## Run Docker container diff --git a/cmd/httpd/main.ha b/cmd/playground/main.ha similarity index 100% rename from cmd/httpd/main.ha rename to cmd/playground/main.ha diff --git a/cmd/httpd/sandbox+darwin.ha b/cmd/playground/sandbox+darwin.ha similarity index 100% rename from cmd/httpd/sandbox+darwin.ha rename to cmd/playground/sandbox+darwin.ha diff --git a/cmd/httpd/sandbox+linux.ha b/cmd/playground/sandbox+linux.ha similarity index 100% rename from cmd/httpd/sandbox+linux.ha rename to cmd/playground/sandbox+linux.ha