bpce livraison
DESCRIPTION
BPCE_LIVRAISON: how to deploy an eZPublish website with one or several third party companiesTRANSCRIPT
BPCE_LIVRAISON: how to deploy your EZpublish website with one or several third party companies
Alexandre SEBBANE, Internet project manager & Internet architect, BPCE
eZ CONFERENCE London 2011
eZ CONFERENCE London 2011 – 16/06/2011
Agenda
1. Introduction
2. Requirements
3. Solution : BPCE_LIVRAISON
4. Create a patch
5. Deploy a patch
6. To improve
7. Questions/Answers
eZ CONFERENCE London 2011 – 16/06/2011
Introduction
� Segmented Network
� IT facilities management
� EzPublish Website
� Complex network schema
eZ CONFERENCE London 2011 – 16/06/2011
Introduction
� Who has access to production server
� Who has someone in production team who know how work ezpublish
� Who has already interve in production environment in order to correct one mistake during the deployment of a patch ?
There is many mistake who can happened so that why we create BPCE_LIVRAISON An Extension to package patch to deploy ezpublish website.
eZ CONFERENCE London 2011 – 16/06/2011
Requirements
� Linux RHELo Because of the “kernel” of this extension :
svn diff --config-dir /etc/subversion --no-diff-deleted --username $USERNAME --password $PASSWORD --summarize $SVN_SERVER/$SVN_MODULE/tags/$BASE_RELEASE $SVN_SERVER/$SVN_MODULE/tags/$LIVR_RELEASE \
| sed -e 's/^\(\w\{1\}\).*http.*\/tags\/[^\/]*\/\(.*\)$/\2 \1/m' \
| awk -vSVN_URL="$SVN_SERVER/$SVN_MODULE/tags/$LIVR_RELEASE/" -vREP_CIBLE="$REP_CIBLE" -vUSERNAME="$USERNAME" -vPASSWORD="$PASSWORD" -vLOG="$LOG" -vDEL_FILES="$DEL_FILES" '
� SVN for revision control systemo All project is in SVN except the var “directory”
� Noveniniupdate dependencyo To apply ezpublish configuration on deployment environment.
eZ CONFERENCE London 2011 – 16/06/2011
Solution : BPCE_LIVRAISON
� Extension ezpublisho Standard installationo Directory to create in each directoryo Configuration
[PackagingSettings]# -- List of the differents environment# -- Patch to filesystem eZPublish for each environment# -- Parameter to Server SVN# -- Path where patch will be build# -- Excludes List for each environment# -- Delfiles filename# -- Log path# -- batch « DIFF SVN » patch# -- PHP binary path# -- Path of patch directory model[DeploiementSettings]# -- Acces au filesystem eZPublish pour chaque environnement# -- Repertoire de stockage de la sauvegarde filesystem pour chaque environnement# -- Acces au fichier de LOG pour chaque environnement# -- Owner des fichiers installes pour chaque environnement# -- PHP binary path# -- Droits des fichiers installes# -- Chemin de stockage des TAR de livraisons
eZ CONFERENCE London 2011 – 16/06/2011
Solution : BPCE_LIVRAISON
� 2 steps deployment:
o Create a patch.
o Deploy it.
eZ CONFERENCE London 2011 – 16/06/2011
Create a patch : choose the begin tag
eZ CONFERENCE London 2011 – 16/06/2011
Create a patch : choose the end tag
eZ CONFERENCE London 2011 – 16/06/2011
Create a patch : choose the environment to deliver
eZ CONFERENCE London 2011 – 16/06/2011
Create a patch : add SQL to insert into the eZpublish Database
eZ CONFERENCE London 2011 – 16/06/2011
Create a patch : add SQL to insert into the eZpublish cluster Database
eZ CONFERENCE London 2011 – 16/06/2011
Create a patch : add comment for history.
eZ CONFERENCE London 2011 – 16/06/2011
Create a patch : Build in progress
eZ CONFERENCE London 2011 – 16/06/2011
Create a patch : patch created, you can see creation log.
eZ CONFERENCE London 2011 – 16/06/2011
Create a patch : Go to the detail of the patch
� Download It
eZ CONFERENCE London 2011 – 16/06/2011
Time to deploy …
Be careful :
you have to test your deployment in a preproduction environment to verify the bugs are gone.
eZ CONFERENCE London 2011 – 16/06/2011
Deploy a patch
� Copy the patch in the patch directory in the environment to deploy
� Go in ssh in the directory
� Type “sh nameofthepatch.bin”
� The patch is beginning deployment.o Backup
o Deployment of the patch.
o Verify and Arrange the file rights
o Delete of deleted files.
o Regenerates autoloads.
o Regenerate configuration files with noveniniupdate.
o Clear the cache.
� Patch is deploy.
eZ CONFERENCE London 2011 – 16/06/2011
Deploy a patch : the log
================================================================ Beginning of the deployment ================================================================
-- Begin the backup ---- Creating directory /data/www/ponant-int/save/4.2.0.86 ---- Files backup
-- End of the backup --
-- Deployment ---- Extract files --
-- Update rights --
-- Copy files --
-- Delete the outdated files --
-- Regenerates autoloads file --
-- Update version file --
-- Update of the configuration --
============================================================== End of the deployment ==============================================================
eZ CONFERENCE London 2011 – 16/06/2011
To improve
� Replace sql access by ezpersistent object.
� Add Multi-language support.
� Improve the cache clearing.
� Add support of others revision control system.
Thanks !
Questions ?
Alexandre SEBBANE
Twitter : @alexsebbaneBlog : http://www.sebbane.org/blog/