CLI Overview and Prequisites
The Cloudscript CLI helps you convert, plan, deploy, and manage your infrastructure efficiently. See the "Get Started" page to ensure your environment is properly set up.
Infrastructure as Code (IaC) Directory
When you convert a .cloud
configuration, the CLI generates standardized infrastructure code in an IaC
directory. This includes:
Terraform configurations for cloud resources
Kubernetes manifests for container orchestration
Ansible playbooks for configuration management
File References
The CLI supports referencing external files within your .cloud
configuration using the file()
function. This is particularly useful for:
IAM policies
Configuration files
Scripts
Other JSON/YAML resources
Example:
Prerequisites
Before using the Cloudscript CLI, ensure you have the following installed:
Terraform (latest version recommended)
Kubernetes CLI (kubectl)
Ansible
Python 3.6 or later
Docker (for local testing)
AWS CLI (configured with appropriate credentials)
GCP CLI (if using Google Cloud Platform)
AWS Configuration
The CLI requires proper AWS credentials configuration. You can set this up by:
Installing the AWS CLI
Running
aws configure
Providing your AWS access key ID and secret access key
GCP Configuration
For Google Cloud Platform:
Install the Google Cloud SDK
Run
gcloud auth login
Set your default project with
gcloud config set project PROJECT_ID
Directory Structure
When working with Cloudscript, maintain the following directory structure for optimal operation:
Last updated