Files
my-rook-config/images/cockroachdb/Makefile
T
Blaine Gardner 60b4a1e4d3 Image make: Move save image step to release builds
The image save step in the image build makefiles takes half or more of
the time of builds, and this step is not necessary for development
builds. Move this functionality to the `build/release/Makefile` so that
images are saved during release builds but not during dev builds. This
will allow developers to iterate more quickly on their builds.

Signed-off-by: Blaine Gardner <blaine.gardner@suse.com>
2018-08-23 09:49:56 -06:00

35 lines
1.1 KiB
Makefile
Executable File

# Copyright 2018 The Rook Authors. All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
include ../image.mk
# ====================================================================================
# Image Build Options
COCKROACHDB_IMAGE = $(BUILD_REGISTRY)/cockroachdb-$(GOARCH)
TEMP := $(shell mktemp -d)
# ====================================================================================
# Build Rook CockroachDB
do.build:
@echo === docker build $(COCKROACHDB_IMAGE)
@cp Dockerfile $(TEMP)
@cp $(OUTPUT_DIR)/bin/linux_$(GOARCH)/rook $(TEMP)
@docker build $(BUILD_ARGS) \
-t $(COCKROACHDB_IMAGE) \
$(TEMP)
@rm -fr $(TEMP)