Skip to content

Restart a service

Description

Some times you need to restart a services. There are some procedures to do this task. Normally we use the command line tool or Argocd user interface. In both cases we delete the current pod and the definition of the deployment will launch a new one.

Requirements

If you want to use command line tool you need kubectl installed and configured.
If you want to use the argocd user interface you need a github user that is part of the team 1doc3 developers to get read only access or senior to have write access.

Procedure

Using the command line tool

Use the next command to discover all pods for an specific namespace
> kubectl -n <namespace> get pods
NAME READY STATUS RESTARTS AGE
apiv3-554c6bc68d-299xg 1/1 Running 0 5h34m
auth-55fc8fb6f5-dv4km 1/1 Running 0 30h
graph-6598d44947-24fvk 1/1 Running 0 3d
moapi-84cfd496d9-8hv6m 1/1 Running 0 29h
notifications-5b6775cd46-vnrd9 1/1 Running 0 2d4h
rtime-6bf5556964-495wv 1/1 Running 0 3d*
Use the next command to delete the pod
> kubectl -n <namespace> delete pod auth-55fc8fb6f5-dv4km

Using argocd website

Signin into argocd website using the next link:
In the applications page select the namespace of the pod you want to restart
Using the tree mode view select the options button of the pod you want to restart
image.png
Select the delete option

Want to print your doc?
This is not the way.
Try clicking the ⋯ next to your doc name or using a keyboard shortcut (
CtrlP
) instead.