kubernetes-plugin

(★ 2,310)

Jenkins plugin to run dynamic agents in a Kubernetes/Docker environment

파일 탐색기

  • .dockerignore
  • .git-blame-ignore-revs
  • .gitignore
  • CHANGELOG-archive.md
  • CLAUDE.md
  • configuration.png
  • credentials.png
  • Dockerfile
  • Jenkinsfile
  • kind-preload.sh
  • kind.sh
  • LICENSE
  • pom.xml
  • README.md

# CDN으로 사용하기

jsDelivr

jsDelivr는 공개 GitHub 리포지토리를 별도 설정 없이 CDN으로 즉시 서빙합니다. 버전과 파일을 고르면 웹페이지에 바로 붙일 수 있는 링크와 예시 코드가 만들어집니다.

명령어 용어집

이 문서에서 사용된 명령어를 모아봤습니다. 낯선 명령어가 있다면 펼쳐서 확인해보세요.

🔍

docker build

설명 보기 ▼

Build an image from a Dockerfile.

docker build .

Build a Docker image using the Dockerfile in the current directory:

docker build {{github.com/creack/docker-firefox}}

Build a Docker image from a Dockerfile at a specified URL:

docker build {{[-t|--tag]}} {{name:tag}} .

Build a Docker image and tag it:

🔍

docker run

설명 보기 ▼

This command is an alias of `docker container run`.

tldr docker container run

View documentation for the original command:

🔍

gcloud container

설명 보기 ▼

Manage containerized applications on Kubernetes and clusters.
See also: `gcloud`.

gcloud auth configure-docker

Register `gcloud` as a Docker credential helper:

gcloud container clusters create {{cluster_name}}

Create a cluster to run GKE containers:

gcloud container clusters list

List clusters for running GKE containers:

🔍

git

설명 보기 ▼

분산 버전 관리 시스템.
`commit`, `add`, `branch`, `checkout`, `push` 등의 특정 하위 명령어는 고유의 문서가 따로 있습니다.
더 많은 정보: <https://git-scm.com/docs/git>.

git init

하위 명령어 실행:

git clone {{https://example.com/repo.git}}

특정 레파지토리 위치에서 Git 하위 명령어 실행:

git status

주어진 설정으로 Git 하위 명령어 실행:

🔍

kind

설명 보기 ▼

Docker 컨테이너 "노드"를 사용하여 로컬 Kubernetes 클러스터를 실행.
Kubernetes 자체 테스트를 위해 설계되었으나, 로컬 개발이나 지속적 통합에도 사용 가능.
더 많은 정보: <https://github.com/kubernetes-sigs/kind>.

kind create cluster --name {{cluster_name}}

로컬 Kubernetes 클러스터 생성:

kind delete clusters {{cluster_name}}

하나 이상의 클러스터 삭제:

kind get {{clusters|nodes|kubeconfig}}

클러스터, 노드 또는 kubeconfig에 대한 세부 정보 가져오기:

🔍

kubectl config

설명 보기 ▼

Manage Kubernetes configuration (kubeconfig) files for accessing clusters via `kubectl` or the Kubernetes API.
By default, the Kubernetes will get its configuration from `${HOME}/.kube/config`.
See also: `kubectx`, `kubens`.

kubectl config get-contexts

Get all contexts in the default kubeconfig file:

kubectl config {{get-clusters|get-contexts|get-users}} --kubeconfig {{path/to/kubeconfig.yaml}}

Get all clusters/contexts/users in a custom kubeconfig file:

kubectl config current-context

Get the current context:

🔍

kubectl create

설명 보기 ▼

Create a resource from a file or from `stdin`.

kubectl create {{[-f|--filename]}} {{path/to/file.yml}}

Create a resource using the resource definition file:

kubectl create {{[-f|--filename]}} -

Create a resource from `stdin`:

kubectl create {{[deploy|deployment]}} {{deployment_name}} --image {{image}}

Create a deployment:

🔍

kubectl delete

설명 보기 ▼

Delete Kubernetes resources.

kubectl delete {{[po|pods]}} {{pod_name}}

Delete a specific pod:

kubectl delete {{[deploy|deployments]}} {{deployment_name}}

Delete a specific deployment:

kubectl delete {{[no|nodes]}} {{node_name}}

Delete a specific node:

🔍

kubectl describe

설명 보기 ▼

Show details of Kubernetes resources.

kubectl describe {{[po|pods]}} {{[-n|--namespace]}} {{namespace}}

Show details of pods in a namespace:

kubectl describe {{[no|nodes]}} {{[-n|--namespace]}} {{namespace}}

Show details of nodes in a namespace:

kubectl describe {{[po|pods]}} {{pod_name}} {{[-n|--namespace]}} {{namespace}}

Show the details of a specific pod in a namespace:

🔍

kubectl get

설명 보기 ▼

Get Kubernetes objects and resources.

kubectl get {{[ns|namespaces]}}

Get all namespaces in the current cluster:

kubectl get {{[no|nodes]}} {{[-n|--namespace]}} {{namespace}}

Get nodes in a specified namespace:

kubectl get {{[po|pods]}} {{[-n|--namespace]}} {{namespace}}

Get pods in a specified namespace:

🔍

kubectl krew

설명 보기 ▼

Plugin manager for `kubectl`.
See also: `kubectl-plugin`.

kubectl krew search

Search for available plugins:

kubectl krew install {{plugin_name}}

Install a plugin:

kubectl krew list

List installed plugins:

🔍

kubectl logs

설명 보기 ▼

Show logs for containers in a pod.

kubectl logs {{pod_name}}

Show logs for a single-container pod:

kubectl logs {{[-c|--container]}} {{container_name}} {{pod_name}}

Show logs for a specified container in a pod:

kubectl logs --all-containers={{true}} {{pod_name}}

Show logs for all containers in a pod:

🔍

kubectl

설명 보기 ▼

Kubernetes 클러스터에서 명령을 실행하기 위한 명령줄 인터페이스.
`run`과 같은 일부 하위 명령에는 자체 사용 설명서가 있습니다.
더 많은 정보: <https://kubernetes.io/docs/reference/kubectl/>.

kubectl get {{pods|service|deployment|ingress|...}} {{[-o|--output]}} wide

리소스에 대한 정보를 자세히 나열:

kubectl label pods {{name}} unhealthy=true

지정된 포드에 'unhealthy' 레이블과 'true' 값을 추가:

kubectl get all

다양한 유형의 모든 리소스 나열:

🔍

minikube start

설명 보기 ▼

Start `minikube` with different configurations.

minikube start --kubernetes-version {{v1.24.0}}

Start `minikube` with a specific Kubernetes version:

minikube start --memory {{2048}} --cpus {{2}}

Start `minikube` with specific resource allocations (e.g., memory and CPU):

minikube start --driver {{virtualbox}}

Start `minikube` with a specific driver (e.g., VirtualBox):

🔍

minikube

설명 보기 ▼

Kubernetes를 로컬에서 실행.
더 많은 정보: <https://minikube.sigs.k8s.io/docs/>.

minikube start

클러스터 시작:

minikube ip

클러스터의 IP 주소 가져오기:

minikube service {{my_service}} --url

노드 포트를 통해 노출된 my_service라는 서비스에 접근하고 URL 가져오기:

🔍

mvn

설명 보기 ▼

Apache Maven: Java 기반 프로젝트를 빌드하고 관리.
더 많은 정보: <https://manned.org/mvn>.

mvn compile

프로젝트 컴파일:

mvn package

컴파일된 코드를 `jar`와 같은 배포 가능한 형식으로 패키지:

mvn package {{[-D|--define]}} skipTests

유닛 테스트를 건너뛰고 컴파일 및 패키지:

🔍

node

설명 보기 ▼

서버 측 JavaScript 플랫폼 (Node.js).
더 많은 정보: <https://nodejs.org/docs/latest/api/cli.html#options>.

node {{path/to/file}}

JavaScript 파일 실행:

node

REPL(대화형 셸) 시작:

node --watch {{path/to/file}}

지정된 파일을 실행하고 가져온 파일이 변경될 때 프로세스를 재시작 (Node.js 버전 18.11+ 필요):

🔍

openssl

설명 보기 ▼

OpenSSL 암호화 도구 모음.
`req`와 같은 일부 하위명령어는 별도의 사용법 문서를 가짐.
더 많은 정보: <https://docs.openssl.org/master/man1/openssl/>.

openssl genpkey -algorithm {{rsa|ec}} -out {{path/to/private.key}} -aes256

개인 키 생성 및 AES-256으로 출력 파일 암호화:

openssl rsa -in {{path/to/private.key}} -pubout -out {{path/to/public.key}}

`rsa`를 사용해 개인키(`private.key`)로부터 공개 키 생성:

openssl req -new -x509 -key {{path/to/private.key}} -out {{path/to/certificate.crt}} -days 365

지정된 기간(365일) 동안 유효한 자체 서명 인증서 생성:

🔍

container

설명 보기 ▼

Create and run Linux containers as lightweight virtual machines on macOS.

container system start

Start the container services (required before running containers):

container run --rm {{[-it|--interactive --tty]}} {{image}} {{sh}}

Run a container from an image interactively and remove it after it exits:

container run {{[-d|--detach]}} --name {{container_name}} {{[-p|--publish]}} {{8080:80}} {{image}}

Run a container in the background with a name and a published port:

// repository documentation