One of the foundations of agile methods are quick feedback loops. Agile development methods aim for quick feedback to the end users. Meanwhile continuous integration is a way to provide quick feedback to the developers about the quality of their code.
Continuous Integration (CI) is a practice within Configuration Management where the integration, building, testing and reporting is automated by tools. As soon as a developer has delivered any code changes a tool is triggered that automatically builds, baselines, tests and provides a report of the status of the code base.
Integration should be done often by developers to avoid any big bang integrations that are complex to solve. Frequent deliveries are valid here too.
The reason for introducing CI is to automate tasks in order to decrease manual overhead in an (agile) environment with short iterations, frequent deliveries and collective code ownership.
Learn more about CI by taking a look at these excellent links:
Continuous Integration - article by Martin Fowler
Continuous Integration - article on Methods & Tools
CI link list - a list of CI links in a CM wiki
Cruise Control - an Open Source tool for continuous integration
Cruise Control Wiki
I have been working as a software consultant for more than 11 years. Because of that I am an eager supporter of lean principles and agile methods.