How to get an analog signal 0 to 12 V DC based on reference 0 to 5 V DC?
You need feedback if you want an exact ratio of 12/5, an open loop transistor will not do this. I would use an opamp with a transistor amplifier. You could also look for an opamp that will output 55 mA (most won't) and leave out the transistor.
You need a rail-to-rail opamp so the output will go to ground. The supply voltage needs to be a few volts higher than 12V if you use a transistor.
Also see the "adding gain" section of this article: https://www.allaboutcircuits.com/technical-articles/how-to-buffer-an-op-amp-output-for-higher-current-part-1/
simulate this circuit – Schematic created using CircuitLab
Build non-inverting OpAmp configuration with a gain of 12/5=2.4 (using a rail-to-rail opamp when you supply it with 12V).
$$V_{out}=\left(1+\frac {R_2}{R_1} \right)V_{in}$$
Using E12 series (which I know by heart):
R2 = 47k and R1 =33k yield a gain of 2.42.
Using E24 or E96 may give nicer results.