Many people misunderstand between continuous integration, continuous delivery, and continuous deployment terms. In this article, I am going to simply these terms in simple words.
When you finished developing on a feature branch and you want to merge your code back to your main branch. You need to run your tests before merging to the main branch to make sure that your feature is not breaking anything. This repetitive task is called continuous integration, but doing this manually every time before merging to the main branch is boring and it will be an issue in large teams. Thanks to CI tools such as Jenkins, Travis CI, and circle CI, you can run your tests automatically and apply CI in your workflow.
Continuous Deployment is all about releasing your app without any human interaction, so whenever a new code is merged to the main branch (after passing your tests), there will be a new release on your production environment.
Continuous Delivery is different from Continuous Deployment in only one thing, you need to click a button to deploy your app or decide when can release your application (human interaction is required).
Now the question is: what is the best choice, Continuous Deployment or Continuous Delivery?
Answer: This depends on your business needs. If you don't have users yet in your system, then continuous deployment should fit your needs, otherwise, you need to follow the continuous delivery approach. I believe you can mix between those two approaches in your workflow by applying continuous deployment on your development branch so that whenever you merge your code to development branch, your app will be deployed automatically on the development environment. If you want to proceed to production, you need to click a button to release your app on production environment.