The ability to interface light with solid-state quantum bits (qubits) is essential for future development of scalable and compact quantum information systems that operate on ultra-fast timescales. Photons act as ideal carriers of quantum information and can serve as an efficient quantum link between matter qubits. Quantum dots (QDs) provide a promising implementation of a matter qubit, which can store quantum information in both excitonic states and highly stable spin states, providing an atom-like system in a semiconductor platform. By coupling these QDs to optical nano-cavities it becomes possible to achieve the strong coupling regime where a QD can modify the cavity spectral response, providing an efficient light-matter interface. In this talk, I will explain that the qubit state of a photon can be controlled by a single solid-state qubit composed of a QD strongly coupled to a photonic crystal cavity. The QD acts as a coherently controllable qubit system that conditionally flips the polarization of a photon reflected from the cavity on picosecond timescales, which implements a controlled NOT logic gate between the QD and the incident photon. Furthermore, the spin of a single electron or hole trapped in a charged QD can be used as a solid-state qubit with long coherence time. I will discuss our recent experimental realization of a quantum phase switch using a solid-state spin confined in a QD strongly coupled to a photonic crystal cavity, where the switch applies a spin-dependent phase shift on a photon.