DevStack CLI
The DevStack CLI is an easy-to-use tool that takes care of establishing an SSH connection with port-forwarding between your local machine and a Cloud Development Environment (CDE). Depending on the method of source code synchronisation, it also handles file syncing.
Get Started
DevStack CLI is available on PyPI (https://pypi.org/).
Prerequisites
The following binaries must be installed to be able to install and use DevStack CLI:
- ssh
- ssh-keyscan
- rsync
- git
- pipx
On Debian/Ubuntu the packages can be installed with
sudo apt install openssh-client rsync git pipx
Installation
You can install DevStack CLI globally with pipx
pipx install devstack-cli
The installation is done when you see this:
installed package devstack-cli 9.0.0, Python 3.8.10
These binaries are now globally available
- devstack-cli
done! ✨ 🌟 ✨
Finally, let's make sure that the PATH variable is updated:
pipx ensurepath
Usage
The command to start devstack-cli
has the following format:
devstack-cli [-h] -H HOSTNAME -s SOURCE_DIRECTORY [-o OUTPUT_DIRECTORY] [-v]
You can find the command specific to your CDE in the self service portal, where your CDE is listed.
Once started, DevStack CLI does the following:
- establishes an SSH connection to your CDE,
- takes care of the port forwarding,
- sets up the local folder (depending on the method of source code synchronisation)
- continuously syncs the deltas (depending on the method of source code synchronisation)
Parameters
Option | Description | Required |
---|---|---|
-H or --hostname | HOSTNAME. The IP or hostname of the CDE. | Yes |
-s or --source-directory | SOURCE_DIRECTORY. A local directory where the sources from the CDE are cached. | Yes |
-o or --output-directory | OUTPUT_DIRECTORY. A local directory where artifacts created on the CDE are stored. | No |
-v or --verbose | Enable debug logging. | No |
-V or --version | Show program's version number and exit. | No |