Skip to content

Get Process Environment From Terminal

View on Twitter

💡 How do you get the ENV vars of a running Node.js (or any) process?

➡️ cat /proc/$PID/environ | tr '\0' '\n'

Prints out the initial environment of the process.

Get the ENV vars of a running process with cat /proc/$PID/environ | tr '0' '
'.

Download the VPS Security Cheatsheet

Use this FREE security cheatsheet to not miss a step when securing your VPS.

A preview of the VPS Security Cheatsheet.

You'll also get tips on building scalable Node.js applications about twice a month. I respect your email privacy. Unsubscribe any time.

You might also like
Restrict SSH Key to Specific Commands Read tip
Public URLs for Your Local Server Read tip
IaaS vs PaaS Explained Using a Store Analogy Read tip