We show that the complex shape of the cosmic ray (CR) spectrum, as recently measured by PAMELA and inferred from Fermi-LAT gamma-ray observations of molecular clouds in the Gould belt, can be naturally understood in terms of basic plasma astrophysics phenomena. A break from a harder to a softer spectrum at blue rigidity Rsimeq 10 GV follows from a transition from transport dominated by advection of particles with Alfven waves to a regime where diffusion in the turbulence generated by the same CRs is dominant. A second break at Rsimeq 200 GV happens when the diffusive propagation is no longer determined by the self-generated turbulence, but rather by the cascading of externally generated turbulence (for instance due to supernova (SN) bubbles) from large spatial scales to smaller scales where CRs can resonate. Implications of this scenario for the cosmic ray spectrum, grammage and anisotropy are discussed.