Skip to content

Commit

Permalink
Added a rule to run dockerized spark
Browse files Browse the repository at this point in the history
Port forwarding so that i can look at the status of spark running in
a container from the host.
  • Loading branch information
vlulla committed Apr 26, 2024
1 parent 902a805 commit cd70cd4
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion dockerize_spark/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ SHELL := bash
MAKEFLAGS += --warn-undefined-variables
MAKEFLAGS += --no-builtin-rules

.PHONY: all clean cleanall
.PHONY: all clean cleanall run
.DEFAULT: all

IMGTAG = dockerized_spark
Expand All @@ -21,6 +21,9 @@ all: Dockerfile
## > sed -e "s/^ARG UID=/&$$(id -u)/g;s/^ARG GID=/&$$(id -g)/g;s/^ARG USER=/&$$(id -un)/g;s/^ARG GROUP=/&$$(id -gn)/g" $< | docker buildx build -t dockerized_spark -f - .
> docker buildx build -f $< --platform linux/amd64 --progress=plain $(if $(NC),--no-cache,) $(UIDARGS) --network=host --tag ${IMGTAG} .

run:
> docker run -it --rm -p 127.0.0.1:4040:4040 ${IMGTAG}

clean:
> docker rmi ${IMGTAG}

Expand Down

0 comments on commit cd70cd4

Please sign in to comment.