<p>I'm running vault and consul as pods in kubernetes, while I'm checking <code>consul catalog service</code> it shows <code>consul</code> alone.</p>

<p>How can I register <code>vault as a service</code>? </p>

<p>I'd tried with the following link, but it didn't work.
<a href="https://learn.hashicorp.com/consul/getting-started/services" rel="nofollow noreferrer">https://learn.hashicorp.com/consul/getting-started/services</a></p>

<p>For registering vault as a service you will have to do the following steps</p>

<ol>
<li>Create a file and write this <code>{"service": {"name": "vault", "tags": ["vault-tag"], "port": 8200}}</code> into it. Name it as <code>vault.json</code></li>
<li>Now, enter this command <code>consul services register vault.json</code></li>
<li>You can now see that vault is registered as a service
<a href="https://i.stack.imgur.com/wa3Us.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/wa3Us.png" alt="vault registeration and checking the consul catalog service"></a></li>
</ol>
