mirror of
https://github.com/clearlinux/dockerfiles.git
synced 2026-11-21 05:14:24 +00:00
Add docker run command line arguments support for tensorflow-serving
Signed-off-by: Jue Wang <wang.jue@intel.com>
This commit is contained in:
@@ -52,3 +52,4 @@ COPY tf_serving_entrypoint.sh /usr/local/bin/
|
||||
RUN chmod +x /usr/local/bin/tf_serving_entrypoint.sh
|
||||
|
||||
ENTRYPOINT ["tf_serving_entrypoint.sh"]
|
||||
CMD ["tensorflow_model_server"]
|
||||
|
||||
@@ -1,6 +1,15 @@
|
||||
#!/bin/bash
|
||||
|
||||
if [ "$1" = 'tensorflow_model_server' ]; then
|
||||
exec tensorflow_model_server --port=8500 --rest_api_port=8501 \
|
||||
--model_name=${MODEL_NAME} --model_base_path=${MODEL_BASE_PATH}/${MODEL_NAME}
|
||||
fi
|
||||
|
||||
if [ "${1#-}" != "$1" ]; then
|
||||
set -- tensorflow_model_server --port=8500 --rest_api_port=8501 \
|
||||
--model_name=${MODEL_NAME} --model_base_path=${MODEL_BASE_PATH}/${MODEL_NAME} "$@"
|
||||
fi
|
||||
|
||||
exec "$@"
|
||||
~
|
||||
|
||||
tensorflow_model_server --port=8500 --rest_api_port=8501 \
|
||||
--model_name=${MODEL_NAME} --model_base_path=${MODEL_BASE_PATH}/${MODEL_NAME} \
|
||||
"$@"
|
||||
|
||||
Reference in New Issue
Block a user