ARG MBT_VERSION=1.2.18
RUN set -ex \
- && npm install -g mbt@${MBT_VERSION} \
+ && npm install -g --unsafe-perm mbt@${MBT_VERSION} \
+ && npm cache clean -g --force \
# smoke test
&& mbt --version
PROJECT_NAME?=sap-e-mobility
-NAME:=mbt-docker
+NAME?=mbt-node16-java11-docker
SUBMODULES_INIT?=false
DOCKER_REGISTRY_USERNAME?=fraggle0
DOCKER_REGISTRY_PASSWORD?=
endif
$(NAME): $(submodules-init)
- docker-compose -p $(PROJECT_NAME) up -d
+ docker-compose -p $(PROJECT_NAME) up -d $(NAME)
$(NAME)-force: $(submodules-init)
- docker-compose -p $(PROJECT_NAME) up -d --build --force-recreate
+ docker-compose -p $(PROJECT_NAME) up -d --build --force-recreate $(NAME)
all: $(NAME)
--- /dev/null
+#!/usr/bin/env sh
+
+images="mbt-node14-java11-docker mbt-node16-java11-docker mbt-node14-java17-docker mbt-node16-java17-docker"
+
+usage() {
+ echo "Usage: $0 [-n <${images// /|}|all>" 1>&2; exit 1;
+}
+
+all() {
+ for image in ${images}; do
+ make NAME=${image}
+ done
+}
+
+[ $# -eq 0 ] && usage
+while getopts "n:h" option; do
+ case "${option}" in
+ n)
+ name=${OPTARG}
+ if [[ ${name} == "all" ]]; then
+ all
+ elif [[ -z "${images##*$name*}" ]]; then
+ make NAME=${name}
+ else
+ usage
+ exit 1
+ fi
+ ;;
+ *|h)
+ usage
+ ;;
+ esac
+done
version: '3.8'
services:
+ # TODO: remove once xmake is configured to push all images
mbt-docker:
platform: linux/amd64
build:
dockerfile: Dockerfile
+ mbt-node16-java11-docker:
+ platform: linux/amd64
+ build:
+ args:
+ NODE_VERSION: 16.18.0
+ SAPMACHINE_VERSION: 11.0.16.1
+ dockerfile: Dockerfile
+ mbt-node14-java11-docker:
+ platform: linux/amd64
+ build:
+ args:
+ NODE_VERSION: 14.20.1
+ SAPMACHINE_VERSION: 11.0.16.1
+ dockerfile: Dockerfile
+ mbt-node16-java17-docker:
+ platform: linux/amd64
+ build:
+ args:
+ NODE_VERSION: 16.18.0
+ SAPMACHINE_VERSION: 17.0.4.1
+ dockerfile: Dockerfile
+ mbt-node14-java17-docker:
+ platform: linux/amd64
+ build:
+ args:
+ NODE_VERSION: 14.20.1
+ SAPMACHINE_VERSION: 17.0.4.1
+ dockerfile: Dockerfile