用terrform for ucloud:
https://www.terraform.io/docs/providers/ucloud/index.html
https://docs.ucloud.cn/compute/terraform/quickstart
用ucloud的py sdk:
具体api配置可以参照这里有一些模板:
https://github.com/ucloud/ucloud-sdk-python
https://docs.ucloud.cn/api/uhost-api/create_uhost_instance