This repository is meant to compliment the go-c8y-cli project by providing the following:
- Installation script
- Default views
- Template (jsonnet) examples
- Shell profile helpers (i.e.
set-session
)
Please see the documentation for more information.
-
Clone the repository
Shell (bash/zsh/fish)
git clone https://github.com/reubenmiller/go-c8y-cli-addons.git ~/.go-c8y-cli cd ~/.go-c8y-cli
PowerShell
git clone https://github.com/reubenmiller/go-c8y-cli-addons.git $HOME/.go-c8y-cli cd $HOME/.go-c8y-cli
-
Install go-c8y-cli binary
Option 1: without sudo
~/.go-c8y-cli/install.sh
Option 2: with sudo If you want to make the c8y globally available, then you can run it using sudo, which will install it under
/usr/local/bin
.sudo -E ~/.go-c8y-cli/install.sh
PowerShell
& "$HOME/.go-c8y-cli/install.ps1"
-
Create a new session (if you do not already have one)
c8y sessions create --host myinfo --username [email protected] --type dev
-
Activate the newly create profile
set-session
-
Check the profile by showing your current user information
c8y currentuser get
-
Run the install script again
Shell (bash/zsh/fish)
~/.go-c8y-cli/install.sh
PowerShell
& $HOME/.go-c8y-cli/install.ps1
Note
go-c8y-cli will only be updated if you are not running the latest version already.