platformsh / legacy-cli

This is the legacy version of Platform.sh's command-line interface. The new version is at: https://github.com/platformsh/cli
https://docs.platform.sh/administration/cli.html
MIT License
224 stars 121 forks source link

Add commands to get and set build resources #1447

Closed pjcdawkins closed 1 month ago

pjcdawkins commented 1 month ago

New commands:

Test for Upsun with:

# Download Upsun config
curl -s https://raw.githubusercontent.com/platformsh/cli/main/internal/config/upsun-cli.yaml > /tmp/upsun-cli.yaml

# Download the build for this PR
curl -s https://pr-1447-ryc5tsy-mpaw4nkgdwaea.eu-2.platformsh.site/platform.phar > /tmp/platform-pr-1447.phar

# Create an alias
alias upsun='CLI_CONFIG_FILE=/tmp/upsun-cli.yaml php /tmp/platform-pr-1447.phar'

# Then run the above commands as "upsun ..."

Test requirements are the same as the legacy CLI installation requirements:

an operating system supported by PHP (Linux, OS X, or Windows) and PHP (5.5.9 or higher) installed, with the following extensions: curl, json, pcre, and phar.

remilejeune2 commented 1 month ago

It's working as expected. Could we use the max_cpu and max_memory values available in the capabilities to validate the input in the CLI?