background

LinkCloud, which was very popular some time ago, paid 300 yuan of experience money for free. Because it is in the public beta phase, the virtual machine created by itself cannot obtain the public network IP. For Xiaobai, there is no way to obtain 80 ports for normal website building. So here's how to obtain Alibaba Cloud public network IP as a normal VPS.

get ready

Start building

1. Log in to the HCaaS account, https://cubepaas.com/

2. Select workload - select deployment service in the upper right corner

3. Just follow the figure below

 Create a VPS with public IP using HCaaS in three minutes

 Create a VPS with public IP using HCaaS in three minutes

  • Name: random
  • Type: stateful
  • Namespace: Default
  • Docker image: select the image address, and fill in the address: registry.cn-zhangjiakou.aliyuncs.com/hanlc/centos7-ssh
  • Update policy: update when rolling upgrade or deleting containers
  • Image pull strategy: pull if it does not exist
  • Domain selection: AliCloud - required
  • Container specification: 2H4G or other user-defined
  • Port mapping: corresponding to the ports to be exposed one by one

    • For example:
    • Container port: 22, protocol: TCP, network mode: L4 load balancer, node listening port: 22
    • Container port: 80, protocol: TCP, network mode: L4 load balancer, node listening port: 80
    • Container port: 8888, protocol: TCP, network mode: L4 layer load balancer, node listening port: 8888
    • Other ports you need to use are added

4. Click Deploy directly and wait for a moment

5. Use the Xshell to connect to port 22 of the public IP for deployment!

 Create a VPS with public IP using HCaaS in three minutes

Account No.: root

password: one hundred and twenty-three thousand four hundred and sixty-five

6. Test and install nginx

yum install wget gcc pcre pcre-devel zlib zlib-devel openssl openssl-devel

wget http://mirrors.sohu.com/nginx/nginx-1.12.0.tar.gz

tar -zvxf nginx-1.12.0.tar.gz

cd nginx-1.12.0

./configure --prefix=/nginx

make & make install

/nginx/sbin/nginx

7. Access port 80

CentOS7 download demo address: http://47.97.68.96/

Some tips from the blogger:
At present, HCaaS is not stable. You can see from the official website that the demo address above has never been closed. Occasionally, it must be a secret upgrade of the official website. So it's OK to play. Don't bother to deploy formal projects~

Article Contents