Skip to content

`jtnctl` is a command-line interface (CLI) tool that simplifies the execution of `kubectl` commands, such as 'logs' and 'port-forward.' It allows you to streamline Kubernetes operations with ease.

Notifications You must be signed in to change notification settings

zakyyudha/jtnctl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

jtnctl - Simplify kubectl Commands

jtnctl is a command-line interface (CLI) tool that simplifies the execution of kubectl commands, such as 'logs', 'port-forward', and 'exec' It allows you to streamline Kubernetes operations with ease.

Requirements

Before using jtnctl, make sure you have the following prerequisites installed on your system:

  • kubectl: The Kubernetes command-line tool (kubectl) is required to interact with Kubernetes clusters. You can download and install kubectl by following the official Kubernetes documentation

Installation

You can install jtnctl using the following methods:

Option 1: Binary Releases (Cross-platform)

Download the latest release for your platform from the Releases page.

MacOS

~ $ wget https://github.com/zakyyudha/jtnctl/releases/download/v1.0.0/jtnctl_v1.0.0_darwin -O jtnctl
~ $ chmod +x jtnctl
~ $ sudo mv jtnctl /usr/local/bin/

Linux

~ $ wget https://github.com/zakyyudha/jtnctl/releases/download/v1.0.0/jtnctl_v1.0.0_linux_amd64 -O jtnctl
~ $ chmod +x jtnctl
~ $ sudo mv jtnctl /usr/local/bin/

Option 2: Building from Source

Clone the repository and build jtnctl:

~ $ git clone https://github.com/zakyyudha/jtnctl.git
~ $ cd jtnctl
~ $ go build -o jtnctl main.go

Usage

Display available commands and options

~ $ jtnctl --help

jtnctl is a CLI tool for simplifying kubectl commands

Usage:
  jtnctl [command]

Available Commands:
  config       Manage configuration settings
  exec         Execute a command in an active service
  help         Help about any command
  logs         View logs of a Kubernetes pod
  port-forward Forward ports for a Kubernetes service

Flags:
  -h, --help   help for jtnctl

Use "jtnctl [command] --help" for more information about a command.

Set the default namespace (e.g., tds-stage)

~ $ jtnctl config set namespace=tds-stage

config-set

Simplify 'kubectl port-forward' command

~ $ jtnctl port-forward [service-name] [destination:source]

config-set

Simplify 'kubectl logs' command

~ $ jtnctl logs [pod-name] [--follow] [--tail=10]

config-set

Simplify 'kubectl exec' command

~ $ jtnctl exec [pod-name] -it -- /bin/bash

config-set

Configuration

jtnctl allows you to config a default namespace using the set command. For example:

~ $ jtnctl config set namespace=tds-stage

The configuration is stored in a ~/.config/jtnctl/config.yaml file. You can modify it directly or use the set command to update values

About

`jtnctl` is a command-line interface (CLI) tool that simplifies the execution of `kubectl` commands, such as 'logs' and 'port-forward.' It allows you to streamline Kubernetes operations with ease.

Resources

Stars

Watchers

Forks

Packages

No packages published