From c373acc43c1adafdf3ec8dc50242cfcab3dfedf1 Mon Sep 17 00:00:00 2001 From: HashiBot <62622282+hashibot-web@users.noreply.github.com> Date: Fri, 14 Oct 2022 17:30:59 -0500 Subject: [PATCH] Update generated website Makefile --- website/Makefile | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/website/Makefile b/website/Makefile index b5087e795..f17908012 100644 --- a/website/Makefile +++ b/website/Makefile @@ -12,7 +12,10 @@ REPO ?= packer # Enable setting alternate docker tool, e.g. 'make DOCKER_CMD=podman' DOCKER_CMD ?= docker +CURRENT_GIT_BRANCH=$$(git rev-parse --abbrev-ref HEAD) +LOCAL_CONTENT_DIR= PWD=$$(pwd) + DOCKER_IMAGE="hashicorp/dev-portal" DOCKER_IMAGE_LOCAL="dev-portal-local" DOCKER_RUN_FLAGS=-it \ @@ -26,6 +29,10 @@ DOCKER_RUN_FLAGS=-it \ --volume "next-dir:/app/website-preview/.next" \ --volume "$(PWD)/.env:/app/.env" \ -e "REPO=$(REPO)" \ + -e "PREVIEW_FROM_REPO=$(REPO)" \ + -e "IS_CONTENT_PREVIEW=true" \ + -e "LOCAL_CONTENT_DIR=$(LOCAL_CONTENT_DIR)" \ + -e "CURRENT_GIT_BRANCH=$(CURRENT_GIT_BRANCH)" \ -e "PREVIEW_MODE=$(PREVIEW_MODE)" # Default: run this if working on the website locally to run in watch mode.