Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'workhorse/Makefile')
-rw-r--r--workhorse/Makefile10
1 files changed, 10 insertions, 0 deletions
diff --git a/workhorse/Makefile b/workhorse/Makefile
index 44b3e2b8248..fe9bf639753 100644
--- a/workhorse/Makefile
+++ b/workhorse/Makefile
@@ -1,4 +1,6 @@
PREFIX=/usr/local
+
+FIPS_MODE ?= 0
PKG := gitlab.com/gitlab-org/gitlab/workhorse
BUILD_DIR ?= $(CURDIR)
TARGET_DIR ?= $(BUILD_DIR)/_build
@@ -19,6 +21,14 @@ EXE_ALL := gitlab-resize-image gitlab-zip-cat gitlab-zip-metadata gitlab-workhor
INSTALL := install
BUILD_TAGS := tracer_static tracer_static_jaeger continuous_profiler_stackdriver
+ifeq (${FIPS_MODE}, 1)
+ # boringcrypto tag is added automatically by golang-fips compiler
+ BUILD_TAGS += fips
+ # If the golang-fips compiler is built with CGO_ENABLED=0, this needs to be
+ # explicitly switched on.
+ export CGO_ENABLED=1
+endif
+
MINIMUM_SUPPORTED_GO_VERSION := 1.11
export GOBIN := $(TARGET_DIR)/bin