📄️ Platform CLI Overview
The platform command-line interface (CLI) is designed to simplify interaction with your Cloud Platform account, allowing you to execute required commands via your local machine’s terminal. It can handle the vast majority of available operations remotely, complementing the wide stack of capabilities provided via the dashboard and platform API.
📄️ Environment Creation
Creation of environments via command line can come in handy for the variety of different solutions (e.g. handling complex DevOps scenarios). So, let’s consider the ways this can be accomplished through.
📄️ Environment Start-Stop
Among the most common operations for environment management provided by CLI, the start and stop ones can be denoted. Wise usage of these methods can help to significantly cut your spends, especially for development and testing environments (for example, you can stop them for the nighttime, while you are sleeping, and start again at the morning to continue the development).
📄️ Environment Cloning
The environment cloning feature is also supported by CLI and can be easily called to help you in creation of new branches/multiple versions of your application. So, to duplicate your environment, just execute the next line:
📄️ Environment Migration
Sometimes, it may be required to move your application to another environment region with better conditions and\or location or, for example, to distribute several cloned environment copies among different hardware sets to achieve increased availability. To perform this remotely, you’ll need to execute the corresponding _migrate_ CLI method via your terminal. So, let’s consider it in more details.
📄️ Server Scaling
When the environment is already created, in some cases it may be required to change its topology - for example, to scale a particular server or the whole environment layer (using the vertical and/or horizontal scaling respectively) due to the changed incoming load. This may be accomplished with the corresponding _changetopology_ CLI method:
📄️ Container Redeploy
In this guide, we’ll show how to redeploy a container from one image tag to another. Herewith, if needed, an option for whole layer redeployment is supported.
📄️ Container Volumes
Container (Docker) Volumes management functionality at the platform allows creating a persistent local storage, designed to be not affected by various operations during container lifecycle. Creation of such a storage right inside a container helps to ensure high level of integrity and prevent loss of important data.
📄️ Mount Points
Mount Points are used to manage connection between data storage server and client, allowing you can work with the shared remote files as easy as with the local ones. With platform CLI it’s possible to configure such mounts via terminal and to include them into specialized scripts for automation.
📄️ VCS Project Deployment
Deployment via VCS is a rather popular and convenient way for project’s integration into the Cloud, as it simplifies operating with app’s sources and allows to easily update its version (either manually or automatically with a certain interval). And the variety of options, available for the VCS deployment management via CLI, gives you the full control on your app.
📄️ Swap Public Ips
The operation of public IPs swap can come in handy for routing of the incoming requests to the required environment or application. It may be especially useful when, for example, switching testing and production environments.
📄️ Installing JPS
In this tutorial, we’ll show how to install a JPS package via CLI. Such a solution can contain steps to create a new environment with predefined customization (e.g. application deployment and configuration) or perform some actions on the existing instances.