I am in favor of using contributor license agreements (CLA) for opensource projects that are expected to be developed in the long run, especially when you develop them as part of your professional activities.
That being said, using a CLA is not always a practical option as it adds a bit of bureaucracy. Indeed, you will need to adapt a CLA like the one from the Apache Software Foundation, and you will have to make sure that people send it back to you before you can accept any contribution from them.
The Linux kernel does not use a CLA, but in 2014 the team introduced a developer certificate of origin (DCO). How does it compare to CLAs?
Read more at Julien Ponge’s Blog