The class of nonunital rings in the language of (binary) multiplication, $xy$, and (binary) subtraction, $x-y$, can be axiomatized by a single identity. For this, see Theorem 4 of
George McNulty
Minimum Bases for Equational Theories of Groups and Rings:
the work of Alfred Tarski and Thomas Green,
Annals of Pure and Applied Logic, 2004.
In fact, Theorem 4 is much stronger than is needed for the conclusion that I have drawn from it. Let me include the theorem here. For this, let $T$ denote an equational theory of rings in a language with $n$ operation symbols. For example, $T$ might be a theory of rings in the language of two binary operations $xy, x-y$, or $T$ might be a theory of rings in the language of two binary operations and one unary operation $xy, x+y, -x$.
Let $\mu T$ denote the least size of a subset $A\subseteq T$ that axiomatizes $T$ (i.e., $A$ is a subset of $T$ and $A$ and $T$ have the same equational consequences). Finally, call $R$ a 'zero ring' if its multiplication is constant.
Theorem 4. Assume that $T$ is finitely axiomatizable (i.e. $\mu T$ is finite).
If $T$ is a theory of nonunital rings and $T$ has a model that is a zero ring of more than one element, then $\mu T = \max(1,n-1)$.
If $T$ is a theory of nonunital rings and $T$ has no model that is a zero ring of more than one element, then $\mu T = 1$.
If $T$ is a theory of unital rings, then $\mu T = 1$.
The theory $T$ of ALL nonunital rings has a model that is a zero ring of more than one element, so if this theory is presented in the language of two binary operations $xy$ and $x-y$, then $\mu T=1$ and the theory has a set of axioms consisting of a single identity.
On the other hand, of the theory is presented in a language of two binary operations $xy, x+y$ and one unary operation $-x$, then $\mu T=2$, so in this language $T$ has a set of axioms consisting of two identities, but no set of axioms consisting of one identity.
Theorem 4 need not be applied to the class of ALL rings, but could be applied to a subvariety, like the class of commutative rings. The theorem gives the same results: if the theory $T$ of ALL nonunital commutative rings is presented in the language of two binary operations $xy$ and $x-y$, then $\mu T=1$. If the theory is presented in a language of three operations $xy, x+y, -x$, then $\mu T=2$.