How to attach a volume to a Bluemix container -


i’m setting container on bluemix using ice command line, every time try attach volume container doesn’t work. mounted folder isn't created in root directory.

my command is:

ice create -p 80 -p 22 --name test --memory 1024 --volume notebooks:/notebooks registry.ng.bluemix.net/repository/app:latest 

docker gives option create volume or allow docker create you. either 1 of these work:

docker run --name mysql_test -v /etc/mysql/conf.d -e mysql_root_password=my-secret-pw -d jw_mysql:latest  

or

docker run --name mysql_test -v /my/custom:/etc/mysql/conf.d -e mysql_root_password=my-secret-pw -d jw_mysql:latest  

for ibm containers, situation different: need create volume before can use it. work:

cf ic volume create dbstorage  cf ic run -p 3306 --name cf_mysql_test -v dbstorage:/etc/mysql/config/conf.d -e mysql_root_password=my-secret-pw -d registry.ng.bluemix.net/jw_image_reg/jw_mysql:latest 

(assuming want use port 3306.)


Comments

Popular posts from this blog

javascript - jQuery: Add class depending on URL in the best way -

caching - How to check if a url path exists in the service worker cache -

Redirect to a HTTPS version using .htaccess -