When you're working with Docker images and containers, some challenges arise, like how to safely make changes to the code, update your base images with new configuration or software, quickly deploy complex setups of multiple Docker containers, and configure links between containers so they can easily interact with each other.
Using CFEngine together with Docker helps you overcome those challenges by providing the following:
- Full automation inside and outside Docker containers that is fast, secure, and scalable
- Reducing deployment complexity of distributed systems through policy-driven orchestration
- Ensuring consistency and compliance across Docker and non-Docker components
- Single, unified solution to provision and manage systems across heterogeneous environments
2. • Complete visibility
and alerting
• Compliance with
self-healing
• OOTB inventory
and reporting
• Repeatable and
error-free
• Deploys to local
or cloud
infrastructure
• Delivers a
standardized
platform
2
• Agile, secure and
scalable
• Policy based and
convergent
• Simple, self-
service
consumption
Intelligent
Infrastructure
Automation
Policy-Based
Application
Deployment
Continuous
Operations with
Self-Healing
Scale Speed Security Stability
CFEngine is IT Automation at
WebScale
3. Distributed, Lightweight Architecture
1. Define Desired State
HUB
3. Verify Actual State
CFEngine
Hub
Design Center
Mission
Portal
Policy Language
2. Ensure
Desired State
CFE Agents
4. The Benefits of Managing Docker
Environments with CFEngine
• Full automation inside and outside Docker
containers – fast, secure, and scalable
• Reduce deployment complexity of distributed
systems through policy-driven orchestration
• Ensure consistency and compliance across Docker
and non-Docker components
• Single, unified solution to provision and manage
systems across heterogeneous environments
5. Managing Docker Environments with CFEngine
Updating base
images
Deploying
complex apps
Creating and Linking
Containers
Front
-end
App
Logic
DB
6. Demo Scenario
• Create custom Docker images on top of base
images
• Provision & manage Docker containers and images
• Manage container connections and internal
configuration
• Detect drift and self heal
• Visualize inventory & create reports
Load
balancer/front
end
Web server #1
Web server #2
DB server
7. Demo Scenario – Image Definitions
Use CFEngine to maintain image
consistency across environments
Ensure hierarchy of
images
9. Demo Scenario – Container Orchestration
The CFEngine policy
uses the information
made available by
Docker through the
container linking
mechanism to correctly
configure its services to
talk to the other
containers
13. Self-Healing Infrastructure “docker ps” command
lists four active
containers
Manually destroy
one container
Second “docker ps”
command lists only
three, after
webserver2 was
destroyed
14. CFEngine Restores Desired State
A few minutes later all
four containers are up
again after CFEngine
resurrected webserver2