Basically, you can't. Sizes of the circuitikz
components are built based on a standard size; you can tweak it to have, for example, 2-input ports at a given distance (if you do not rescale the TikZ coordinates), see here: Needing a dipchip of CircuiTikz with exact pin distance --- you will need to put them at 0.5 cm to have your example with straight lines.
BUT the best solution is using coordinates that are relative to the anchors:
\documentclass[border=10pt]{standalone}
\usepackage[siunitx, RPvoltages]{circuitikz}
\begin{document}
\begin{tikzpicture}
\node[american nand port, draw] at (0,0) (NAND1) {};
\draw (NAND1.in 2) -- ++(-0.5,0) coordinate(p);
\draw (NAND1.in 1) -- ++(-0.5,0) coordinate(p2);
\draw (NAND1.out) coordinate (p3);
\node[left] at (p) {$p$};
\node[left] at (p2) {$p$};
\node[right] at (p3) {$\overline{p}$};
\end{tikzpicture}
\end{document}

Are you sure you do not want standard IEEE ports? If you add
\ctikzset{logic ports=ieee}
you have the option to change pin lengths, see Simple Logic gates with circuitikz - increase I/O line length
As an example, let's see how to make your example work with absolute lengths. If you look at the manual (pag. 119) you discover that the default height of the ports is 0.8 basic units. So if I make the basic unit 1.25cm, the port will be 1 cm tall, and the connections 0.5 cm apart.
\documentclass[border=10pt]{standalone}
\usepackage[siunitx, RPvoltages]{circuitikz}
\ctikzset{bipoles/length=1.25cm}
\begin{document}
\begin{tikzpicture}
\node (p) at (0,0) {$p$};
\node (p2) at (0,0.5) {$p$};
\node (p3) at (2.5,0.25) {$\overline{p}$};
\node[american nand port, draw] at ($(p) + (2.0,0.25)$) (NAND1) {};
\draw (p) -- (NAND1.in 2);
\draw (p2) -- (NAND1.in 1);
\draw (NAND1.out) -- (p3);
\end{tikzpicture}
\end{document}

Still, this solution is not optimal. Rounding errors are prone to create problems (especially to the antialiasing routines of PDF viewers...)
\documentclass{...}
, the required\usepackage
's,\begin{document}
, and\end{document}
. That may seem tedious to you, but think of the extra work it represents for TeX.SX users willing to give you a hand. Help them help you: remove that one hurdle between you and a solution to your problem.