One, that switch does not directly control the motor. It's most likely a few mA at best, as it signals a microcontroller inside the cdrom to open/close the tray.
Two, what you are looking for is simple ohms law. Resistor = (Source Voltage - The Transistor Base/Emitter Drop) / Current Required in Amps. Since the hFE or current multiplication ability of the TIP120 is 1000, so roughly it will allow 1000 times the base current at the collector, any amount of current should be good at the base. Let's just use 5mA. The Base/Emitter drop is 1.25V minimum, as there are two transistor diodes.
Resistor = (5v - 1.25V) / 0.005A or 3.75V / 0.005A = 750Ω or close.
Update To further answer the question, you calculate the base resistor within the safe range of your source (Arduino, 40mA per pin, 200mA total at any given time). The unknown collector current in this case would be minimal for a button. For actual loads like a motor, you could simply max out the transistor by saturating it, giving the base transistor as much current as possible. In this case, you would have to have multiple arduino pins in parallel since the TIP120 base limit is 120mA and the Arduino is 40mA per pin. This is not ideal because you don't know the current at C-E or the amount of voltage it will drop.
The best answer is that you DONT. A proper design will find out how much current will be at the collector. Use a ammeter or multimeter in current mode to find out.
If your load current is 1mA (guesswork on my part) then this will produce 1.5 volts across R3. The voltage on the base to produce this must be about 2.2 volts below Vcc (1.1 volts above 0V when Vcc is 3.3 volts).
If you assume R2 is 10 kohms then R1 will have 1.1 volts across it and R2 will have 2.2 volts across it - this means a current of 220uA. This means R1 is 5 kohms.
Best Answer
It depends on how much precision you think you need....
The simple approach is to simply know that Vbe for a silicon transistor in conduction is ~0.6V or so, and that this voltage must thus appear across R1, thus I(r1) must be ~ 6mA, V(r2) = 20 - 0.6 = 19.4V, I (r2) = 19.4/2.7k = ~7.2mA, so Ib = 7.2 - 6 = 1.2mA (I leave the signs to you as that depends on how you define the current loops).
The more precise approach (and if you need this, you are probably doing it wrong) is to use the Ebbers-Moll equation which relates Ib to Vbe and temperature (The base-emitter junction is basically a silicon diode), but that turns into a mess of maths because the Vbe ->Ib relation is exponential, and you almost never need this (Unless you are Jim Williams).
R3 provides the base current for the second transistor (And by the way this circuit will destroy itself as you power it up, because until the supply voltage becomes sufficient to turn the first transistor on, there is little to limit the current in D1 and the second transistor except perhaps for the value of R3, but that depends on the HFE of the second transistor that is not a well controlled parameter.
Regards, Dan.