Installing sloctl
Reading time: 0 minute(s) (0 words)
This guide provides platform-specific instructions for installing sloctl.
MacOS
- Using Homebrew (recommended)
- Manual installation
- Install Homebrew if required.
- Run the following commands in your terminal:
brew tap nobl9/sloctl
brew install sloctl
💡Homebrew unsupported macOS version resolution
If you encounter a Homebrew error, such as:
Error: unknown or unsupported macOS version: :dunno
Resolve it by runningbrew update-reset
- Verify that
sloctlis installed correctly:sloctl version # Displays the installed version of sloctl
- Download the
sloctlbinary file from the sloctl releases page. - Place the file in your system path and rename it
sloctl. - Grant executable permissions to the binary.
- Run the following commands in your terminal:
sudo mkdir -p /usr/local/bin # Ensure the /usr/local/bin directory exists to store the sloctl binary
sudo cp ~/Downloads/sloctl /usr/local/bin/ # Move the binary to the Downloads folder
sudo chmod a+rx /usr/local/bin/sloctl # Ensure the stored sloctl binary is properly configured to be executable and accessible to all users
open /usr/local/bin # Navigate to the bin folder in Finder - Right-click
sloctl. Select Open to authorize it on macOS. - Verify that
sloctlis installed correctly:sloctl version # Displays the installed version of sloctl
Windows
- Download the
sloctlbinary file from the sloctl releases page. - Create the
/nobl9/folder in the following locations:- Admin users in
C:\Program Files\ - Non-admin users in your user directory
- Admin users in
- Rename the binary to
sloctl.exe. - Move
sloctl.exeto your created directory (Step 2). - Verify that
sloctlis installed correctly:sloctl version # Displays the installed version of sloctl
After completing these steps, admin users have sloctl properly installed and ready for configuring.
When you're installing sloctl as a non-admin user, add sloctl to the system path to finish installation:
- Go to Control Panel > System and Security > System.
- Click Advanced System Settings > Environment variables.
- Select Path for User variables (or for System Variables, when this section is available).
- Click Edit. Add the directory path where you placed
sloctl.exeand save your changes. - Verify that
sloctlis installed correctly:sloctl version # Displays the installed version of sloctl
Linux
- Download the
sloctlbinary file from the sloctl release page. - Move the binary file to a directory included in your
$PATH, like/usr/local/bin. - Rename the binary file to
sloctl. - Type
sloctlin your terminal to run the program. - Verify that
sloctlis installed correctly:sloctl version # Displays the installed version of sloctl
💡Permission errors on Linux
If you encounter file permission issues, ensure your sloctl binary has executable permissions.
You can run chmod +x sloctl to add execute permissions to the file.
Alternatively, use other chmod option.
Go
- Install the latest version of
sloctl:go install github.com/nobl9/sloctl/cmd/sloctl@latest - Verify installation.
Ensure the$GOPATH/bindirectory is included in your system's$PATH. If not, add it with this example command:export PATH=$PATH:$(go env GOPATH)/bin - Verify that
sloctlis installed correctly:sloctl version # Displays the installed version of sloctl
Docker
- Pull the latest
sloctlimage from the repository:docker pull nobl9/sloctl - Build the Docker image:
Replace<IMAGE_NAME>with your preferred image namedocker build -t <IMAGE_NAME>. - To use environment variables for authentication, set them following the configuration guide.
- Run the image:
docker run
-e SLOCTL_CLIENT_ID=$SLOCTL_CLIENT_ID \
-e SLOCTL_CLIENT_SECRET=$SLOCTL_CLIENT_SECRET \
<IMAGE_NAME> get slos --no-config-file - Verify that
sloctlis installed correctly:sloctl version # Displays the installed version of sloctl