blob: b17f92ece83dec62a1a7db260ea774dd2e816eb8 [file] [log] [blame]
Matteo Scandolo1d01b692018-10-03 15:53:36 -07001# Copyright 2017 the original author or authors.
2#
3# Licensed under the Apache License, Version 2.0 (the "License");
4# you may not use this file except in compliance with the License.
5# You may obtain a copy of the License at
6#
7# http://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS,
11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12# See the License for the specific language governing permissions and
13# limitations under the License.
14
15
16# Container are build via the `make build` commands.
17
18# Optional parameters are:
19# `REGISTRY=192.168.99.100:3000/ REPOSITORY=xosproject/ DOCKER_BUILD_ARGS="--no-cache" TAG=dev make build`
20
21ifeq ($(TAG),)
22TAG := candidate
23endif
24
25ifeq ($(REPOSITORY),)
26REPOSITORY := xosproject/
27endif
28
29summary:
30 @echo Building images with:
31 @echo " Build args: $(DOCKER_BUILD_ARGS)"
32 @echo " Registry: ${REGISTRY}"
33 @echo " Repository: ${REPOSITORY}"
34 @echo " Tag: ${TAG}"
35
36build: summary xos-base xos-libraries xos-client xos-core xos-synchronizer-base
37
38xos-base:
39 docker build $(DOCKER_BUILD_ARGS) -t ${REGISTRY}${REPOSITORY}xos-base:${TAG} -f Dockerfile.base .
40
41xos-libraries:
Matteo Scandolo12651d72019-02-21 15:15:29 -080042 docker build --no-cache $(DOCKER_BUILD_ARGS) -t ${REGISTRY}${REPOSITORY}xos-libraries:${TAG} -f Dockerfile.libraries ../..
Matteo Scandolo1d01b692018-10-03 15:53:36 -070043
44xos-client:
45 rm -rf tmp.chameleon
46 cp -R ../../../../component/chameleon tmp.chameleon
Matteo Scandolo12651d72019-02-21 15:15:29 -080047 docker build --no-cache $(DOCKER_BUILD_ARGS) -t ${REGISTRY}${REPOSITORY}xos-client:${TAG} -f Dockerfile.client ../..
Matteo Scandolo1d01b692018-10-03 15:53:36 -070048
49xos-core:
Matteo Scandolo12651d72019-02-21 15:15:29 -080050 docker build --no-cache $(DOCKER_BUILD_ARGS) -t ${REGISTRY}${REPOSITORY}xos-core:${TAG} -f Dockerfile.xos-core ../..
Matteo Scandolo1d01b692018-10-03 15:53:36 -070051
52xos-synchronizer-base:
Matteo Scandolo12651d72019-02-21 15:15:29 -080053 docker build --no-cache $(DOCKER_BUILD_ARGS) -t ${REGISTRY}${REPOSITORY}xos-synchronizer-base:${TAG} -f Dockerfile.synchronizer-base ../..