Run KDX CLI in a container without installing binaries on your system.
# Pull the latest imagedocker pull kodexa/kdx:latest# Run kdx commandsdocker run --rm kodexa/kdx:latest --version# Mount local files for workspace operationsdocker run --rm -v $(pwd):/workspace kodexa/kdx:latest get workspaces# Create an alias for conveniencealias kdx='docker run --rm -v $(pwd):/workspace -v ~/.kodexa:/root/.kodexa kodexa/kdx:latest'
When using Docker, mount ~/.kodexa to persist your profile configuration across container runs.
# Get the latest version and download the .deb packageVERSION=$(curl -s https://api.github.com/repos/kodexa-ai/kdx-cli/releases/latest | grep '"tag_name"' | sed 's/.*"v\(.*\)".*/\1/')wget "https://github.com/kodexa-ai/kdx-cli/releases/download/v${VERSION}/kdx_${VERSION}_linux_amd64.deb"# Install with dpkgsudo dpkg -i "kdx_${VERSION}_linux_amd64.deb"# Verify installationkdx --version
# Get the latest version and download the .rpm packageVERSION=$(curl -s https://api.github.com/repos/kodexa-ai/kdx-cli/releases/latest | grep '"tag_name"' | sed 's/.*"v\(.*\)".*/\1/')wget "https://github.com/kodexa-ai/kdx-cli/releases/download/v${VERSION}/kdx_${VERSION}_linux_amd64.rpm"# Install with rpmsudo rpm -i "kdx_${VERSION}_linux_amd64.rpm"# Verify installationkdx --version
Clone and build from source for custom modifications or contributions.
# Clone the repositorygit clone https://github.com/kodexa-ai/kdx-clicd kdx-cli# Build for your platformmake build# Or install directly to $GOPATH/binmake install# Verify installationkdx --version
# Check if kdx is in your PATHwhich kdx# If not found, add the installation directory to PATHexport PATH="/usr/local/bin:$PATH"# Make permanent by adding to shell profileecho 'export PATH="/usr/local/bin:$PATH"' >> ~/.bashrc # or ~/.zshrc