Fix the build script to compile the bootstrap in a container

This commit is contained in:
Sameer Rahmani 2021-01-15 18:52:09 +00:00
parent 8546c1c562
commit d154f32079
3 changed files with 6 additions and 4 deletions

View File

@ -1,6 +1,6 @@
THIS_DIR=$(dir $(realpath $(firstword $(MAKEFILE_LIST))))
ROOT_DIR=$(dir $(realpath $(firstword $(MAKEFILE_LIST))))
include $(THIS_DIR)/bootstrap/Makefile
include $(ROOT_DIR)/bootstrap/Makefile
.PHONY: compile
compile: compile-bootstrap

View File

@ -5,7 +5,7 @@ RUN mkdir -p /usr/src/serene
WORKDIR /usr/src/serene
COPY go.mod go.sum ./
RUN go mod download
RUN go mod download -x
COPY . .
# Build the Go app
RUN go build -v ./serene.go

View File

@ -1,7 +1,9 @@
BOOTSTRAP_TAG ?= latest
BOOTSTRAP_DIR = $(ROOT_DIR)/bootstrap
compile-bootstrap:
docker build -t serene-lang/serene-bootstrap:$(BOOTSTRAP_TAG) .
echo ">>>>>>>>>>> $(BOOTSTRAP_DIR)"
docker build -t serene-lang/serene-bootstrap:$(BOOTSTRAP_TAG) $(BOOTSTRAP_DIR)
clean-bootstrap:
docker rmi serene-lang/serene-bootstrap:$(BOOTSTRAP_TAG)