kjobctl

module
v0.0.0-...-298fb37 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 3, 2024 License: Apache-2.0

README

kjobctl

ML/AI/Batch Jobs Made Easy

Description

The kubectl-kjob plugin, kjobctl, allows you to list, describe and create jobs.

Read the overview to learn more.

Getting Started

Prerequisites
  • go version v1.23+
  • kubectl version v1.27+.
  • Access to a Kubernetes v1.27+ cluster.
To Install

Install the CRDs into the cluster:

make install

Install kubectl kjob plugin:

make kubectl-kjob
sudo cp ./bin/kubectl-kjob /usr/local/bin/kubectl-kjob

Additionally, you can create an alias kjobctl to allow shorter syntax:

echo 'alias kjobctl="kubectl kjob"' >> ~/.bashrc
# Or if you are using ZSH
echo 'alias kjobctl="kubectl kjob"' >> ~/.zshrc

Autocompletion:

echo '[[ $commands[kubectl-kjob] ]] && source <(kubectl-kjob completion bash)' >> ~/.bashrc
# Or if you are using ZSH
echo '[[ $commands[kubectl-kjob] ]] && source <(kubectl-kjob completion zsh)' >> ~/.zshrc

cat <<EOF >kubectl_complete-kjob
#!/usr/bin/env sh

# Call the __complete command passing it all arguments
kubectl kjob __complete "\$@"
EOF

chmod u+x kubectl_complete-kjob
sudo mv kubectl_complete-kjob /usr/local/bin/kubectl_complete-kjob
To Uninstall

Delete the APIs(CRDs) from the cluster:

make uninstall

Delete kubectl kjob plugin:

sudo rm /usr/local/bin/kubectl-kjob

NOTE: Run make help for more information on all potential make targets

License

Copyright 2024 The Kubernetes Authors.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Directories

Path Synopsis
apis
v1alpha1
Package v1alpha1 contains API Schema definitions for the kjobctl.x-k8s.io v1alpha1 API group +kubebuilder:object:generate=true +groupName=kjobctl.x-k8s.io
Package v1alpha1 contains API Schema definitions for the kjobctl.x-k8s.io v1alpha1 API group +kubebuilder:object:generate=true +groupName=kjobctl.x-k8s.io
client-go
clientset/versioned/fake
This package has the automatically generated fake clientset.
This package has the automatically generated fake clientset.
clientset/versioned/scheme
This package contains the scheme of the automatically generated clientset.
This package contains the scheme of the automatically generated clientset.
clientset/versioned/typed/apis/v1alpha1
This package has the automatically generated typed clients.
This package has the automatically generated typed clients.
clientset/versioned/typed/apis/v1alpha1/fake
Package fake has the automatically generated clients.
Package fake has the automatically generated clients.
cmd
hack
tools Module
pkg
cmd
test

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL