3. New optimized for any
workload infrastructure
built on modern DevOps
stack, like Docker, Rancher
ready for scaling
3
4. Dockerized app
5 Key Benefits of Docker: CI, Version Control, Portability,
Isolation and Security for your infrastructure
4
5. Stage 1:
Dockerize
project
Preparing to build
Your project
should be built
being ready to
deploy docker
image:
- M2 requires
to build static
files,
compilation
code, etc
- M1 can
assembly
modules via
composer
Shared folder
All shared
resources like
“media”, “var”,
“log”, “ftp folders”
should be defined
as docker
volumes
Docker registry
Except repository
for source code,
you also need
storage for
images
(snapshots) which
are ready to
deploy to any
environment.
Prepare access to
hub.docker.com,
quay.io, etc
5
7. Stage 2:
Docker
Infrastructure
7 Rancher is not a container orchestrator. It's a complete container
management platform that includes everything you need to manage
containers in production. You can quickly deploy multiple Docker
and Kubernetes clusters across multiple clouds with the click of a
button.
RancherOS is a great place to run Docker and Kubernetes. It's an
ultra-lightweight Linux distribution which enables you to boot your
containers in seconds as well as run Docker, Kubernetes and Rancher
at Scale in production.
8. Stage 2:
Docker
Infrastructure
8
Your infrastructure for now has no
vendor lock to hosting providers.
Choose any within your budget and get
benefits like standard autoscaling,
backups, monitoring via external tools
integrated only in your infrastructure.
Also for your
own servers:
9. Monitoring
Your infrastructure can
plugin many tools for
monitoring:
- NewRelic
- Splunk
- Loggly
- Prometheus
- etc
Loadbalancer
We can handle any high
load traffic via
high-availability
loadbalancer and deliver
all requests to many
server nodes:
- HAProxy
- Nginx
CI
We can integrate any CI
tools for automation of
building, testing, staging
purposes:
- Jenkins
- CircleCI
- GitLab CI
- Bitbucket pipelines
Alerting
- Pingdom
- Custom
healthcheckers
- Native cloud tools
(like Cloudwatch)
Storage
For shared files we can
use:
- NFS backend
- GlasterFS
- Amazon EFS, EBS
Backups
- Ready to use
utilities (database,
storages)
- Cron-tasks to
upload backups on
any remote server
& Amazon S3, etc
Stage 3:
Production
tools
9
10. Results
10
1. You have high-availability self-restoring modern
infrastructure
2. Any environments (prod, stage, test, local) have the
same basis: identical.
3. Easy to make changes & add new capabilities (new
PHP version, replace Database to RDS & vice versa)
4. Autoscale ready
5. Zero-downtime & faster deploy
6. Developer friendly
7. High security
8. Performance improvement
9. A/B testing
11. How it works
Example:
11
● Perform audit of the project
● Apply recommendations (upgrade Magento or PHP
version, etc)
● Choose infrastructure tools & options for hosting
● Dockerize the project (plan)
● Build local environment for project
● Build stage infrastructure
● Configure CD/CI tools
● Prepare other options like monitoring, backups
● Migrate production to new infrastructure
Rancher Docker Hub
LB
NFS Storage RDS Cache
Node: Nginx+PHP7+M2
Node: Nginx+PHP7+M2