Using Alfresco for Image Transformation

Showing results for 
Search instead for 
Did you mean: 

Using Alfresco for Image Transformation

0 0 1,838

Obsolete Pages{{Obsolete}}

The official documentation is at:

Digital Asset Management

Note: Work In Progress

Alfresco can be used for many aspects of Digital Asset Management, including image transformation.  These instructions are written for someone using the Mac OS X operating system.

  1. Install Alfresco 3.0b or greater.
  2. Install/Configure ImageMagick
    1. Determine whether ImageMagick is installed
      1. At the command line, type 'convert'.  This is an ImageMagick utility.  If it is not found, ImageMagick is at the very least not configured (but may be installed)
      2. Check /usr/bin for the convert utility.  If it exists there, ImageMagick is installed on your system.  You may need to update your $PATH to include /usr/bin.  If not, it is either elsewhere on your system or not installed.
    2. If ImageMagick is not installed, install and configure it.  Learn how to do that here:
  3. Extend the Alfresco content model with an Aspect to support image transformation options.
    1. I did this by adding the following new aspect to the Alfresco content model in $TOMCAT_HOME/webapps/alfresco/WEB-INF/classes/alfresco/model/contentModel.xml:

        <aspect name='cm:imageTransformationOptions'>
            <title>Image Transformation Options</title>
                <property name='cm:commandOptions'>
                    <title>Command Options</title>
                <property name='cm:resize'>
                    <title>Resize The Image</title>
                <property name='cm:resizeWidth'>
                    <title>Resize Width</title>
                <property name='cm:resizeHeight'>
                    <title>Resize Height</title>
                <property name='cm:resizeMaintainAspectRatio'>
                    <title>Resize Maintain Aspect Ratio</title>
                <property name='cm:resizePercent'>
                    <title>Resize Percent</title>
                <property name='cm:resizeToThumbnail'>
                    <title>Resize To Thumbnail</title>

  1. Add the following web client customization in $TOMCAT_HOME/webapps/alfresco/WEB-INF/classes/alfresco/extension/web-client-config-custom.xml (see


    <config evaluator='aspect-name' condition='cm:imageTransformationOptions'>
            <show-property name='cm:commandOptions' display-label-id='commandOptions' />
            <show-property name='cm:resize' display-label-id='resize' read-only='true' />
            <show-property name='cm:resizeWidth' display-label-id='resizeWidth'/>
            <show-property name='cm:resizeHeight' display-label-id='resizeHeight'/>
            <show-property name='cm:resizeMaintainAspectRatio' display-label-id='resizeMaintainAspectRatio'/>
            <show-property name='cm:resizePercent' display-label-id='resizePercent'/>
            <show-property name='cm:resizeToThumbnail' display-label-id='resizeToThumbnail'/>
    <config evaluator='string-compare' condition='Action Wizards'>
            <aspect name='cm:imageTransformationOptions'/>

  1. Other stuff TBA