IBM Bluemix is a cloud platform as a service (PaaS) developed by IBM. It supports several programming languages and services as well as integrated DevOps to build, run, deploy and manage applications on the cloud.
Introduction
Bluemix Kubernetes can create and run containerized app easily even with privileged permission.You can add a credit card to upgrade to Pay-As-You-Go account that can run 512M app all the time, or run 256M app with some limit after trial.
Deploy
Containers–>Create Cluster–>waitting for deploy
see Access
page
Install Bluemix CLI (Make sure sudo and curl have installed before):
1 |
sh <(curl -fsSL https://clis.ng.bluemix.net/install/linux) |
Install kubectl binary:
1 |
wget https://raw.githubusercontent.com/putiyeb/Bluemix/master/kubectl_install.sh && bash kubectl_install.sh |
install IBM Bluemix Container Service plug-in:
1 |
bx plugin install container-service -r Bluemix |
Log in to your Bluemix account(different region has different API link, detail see YOUR Access page):
1 |
bx login -a https://api.au-syd.bluemix.net |
Initialize the IBM Bluemix Container Service plug-in:
1 |
bx cs init |
Set your terminal context to your cluster(mycluster is your cluster name created before):
1 |
bx cs cluster-config mycluster |
After running above command, you can see the response information include the "export****"
line, run it:
1 |
export KUBECONFIG=/Users/ibm/.bluemix/plugins/container-service/clusters/mycluster/kube-config-mel01-mycluster.yml |
You can verify your worker nodes by running some Kubernetes commands:
1 |
kubectl get nodes |
In a VPS, you may not use the web browser to view http://127.0.0.1:8001/ui
. We can use nginx
to redirect it to the VPS ip.
1 2 3 4 5 6 7 8 9 10 11 |
sudo apt-get install -y nginx sudo vim /etc/nginx/conf.d/default.conf #save the following content server { listen 8000; server_name _; location / { proxy_pass http://127.0.0.1:8001; } } sudo service nginx restart |
You can access your Kubernetes dashboard now:
1 2 3 |
sudo apt-get install screen screen -S dl kubectl proxy |
visit http://VPS IP:8000/ui
to control your service.
Usage
Input the Docker Hub image information:
Make sure memory is less than 512M and run as privileged:
Check the final public port:
Go to Worker Nodes
page
OR using command to view Cluster Node public IP:
1 2 |
bx cs clusters bx cs workers mycluster |
Reference link:http://51.ruyo.net/p/4776.html