Cloudron makes it easy to run web apps like WordPress, Nextcloud, GitLab on your server. Find out more or install now.


EspoCRM Extension installation failure



  • I've purchased the EspoCRM Advanced Pack (https://www.espocrm.com/extensions/advanced-pack/) and gone to install it per the instructions (https://www.espocrm.com/documentation/administration/extensions/) to an EspoCRM instance running on one of my Cloudron installations. The file uploads fine, but the extension installer fails, spitting out the following error(s):

    Error: Permission denied for 
    application/Espo/Modules/Advanced/Acl, 
    application/Espo/Modules/Advanced/Business/Report/EmailBuilder.php, 
    application/Espo/Modules/Advanced/Business/Workflow/AssignmentRules, 
    application/Espo/Modules/Advanced/Controllers, 
    application/Espo/Modules/Advanced/Core/Bpmn, 
    application/Espo/Modules/Advanced/Core, 
    application/Espo/Modules/Advanced/Entities, 
    application/Espo/Modules/Advanced/Hooks/BpmnProcess, 
    application/Espo/Modules/Advanced/Hooks/BpmnUserTask/Resolve.php, 
    application/Espo/Modules/Advanced/Hooks/Common/Workflow.php, 
    application/Espo/Modules/Advanced/Hooks/Workflow/ReloadWorkflows.php, 
    application/Espo/Modules/Advanced/Jobs, 
    application/Espo/Modules/Advanced/Notificators/BpmnUserTask.php, 
    application/Espo/Modules/Advanced/Reports, 
    application/Espo/Modules/Advanced/Repositories, 
    application/Espo/Modules/Advanced/Resources/i18n/cs_CZ, 
    application/Espo/Modules/Advanced/Resources/i18n/de_DE, 
    application/Espo/Modules/Advanced/Resources/i18n/en_US, 
    application/Espo/Modules/Advanced/Resources/i18n/fr_FR, 
    application/Espo/Modules/Advanced/Resources/i18n/it_IT, 
    application/Espo/Modules/Advanced/Resources/i18n/pl_PL, 
    application/Espo/Modules/Advanced/Resources/i18n/ru_RU, 
    application/Espo/Modules/Advanced/Resources/i18n/uk_UA, 
    application/Espo/Modules/Advanced/Resources/layouts/BpmnFlowNode/listSmall.json, 
    application/Espo/Modules/Advanced/Resources/layouts/BpmnFlowchart, 
    application/Espo/Modules/Advanced/Resources/layouts/BpmnProcess, 
    application/Espo/Modules/Advanced/Resources/layouts/BpmnUserTask, 
    application/Espo/Modules/Advanced/Resources/layouts/Report, 
    application/Espo/Modules/Advanced/Resources/layouts/Workflow, 
    application/Espo/Modules/Advanced/Resources/metadata/app, 
    application/Espo/Modules/Advanced/Resources/metadata/clientDefs, 
    application/Espo/Modules/Advanced/Resources/metadata/dashlets, 
    application/Espo/Modules/Advanced/Resources/metadata/entityAcl/Report.json, 
    application/Espo/Modules/Advanced/Resources/metadata/entityDefs, 
    application/Espo/Modules/Advanced/Resources/metadata/scopes, 
    application/Espo/Modules/Advanced/Resources, 
    application/Espo/Modules/Advanced/SelectManagers, 
    application/Espo/Modules/Advanced/Services, 
    client/modules/advanced/css/bpmn.css, 
    client/modules/advanced/fonts, 
    client/modules/advanced/lib/espo-bpmn.js, 
    client/modules/advanced/res/templates/bpmn-flow-node/fields/element/detail.tpl, 
    client/modules/advanced/res/templates/bpmn-flowchart/fields/flowchart, 
    client/modules/advanced/res/templates/bpmn-flowchart/modals/element-detail.tpl, 
    client/modules/advanced/res/templates/bpmn-flowchart/record/panels/flowchart.tpl, 
    client/modules/advanced/res/templates/bpmn-flowchart-element/fields/actions/detail.tpl, 
    client/modules/advanced/res/templates/bpmn-flowchart-element/fields/conditions/detail.tpl, 
    client/modules/advanced/res/templates/bpmn-flowchart-element/fields/flows-conditions/detail.tpl, 
    client/modules/advanced/res/templates/bpmn-flowchart-element/fields/timer, 
    client/modules/advanced/res/templates/bpmn-user-task/modals/resolve.tpl, 
    client/modules/advanced/res/templates/bpmn-user-task/record/resolve.tpl, 
    client/modules/advanced/res/templates/dashlets/options/report.tpl, 
    client/modules/advanced/res/templates/report/fields/email-sending-time/edit.tpl, 
    client/modules/advanced/res/templates/report/fields/email-sending-weekdays, 
    client/modules/advanced/res/templates/report/fields/filters-control, 
    client/modules/advanced/res/templates/report/filters, 
    client/modules/advanced/res/templates/report/modals, 
    client/modules/advanced/res/templates/report/record, 
    client/modules/advanced/res/templates/report/reports, 
    client/modules/advanced/res/templates/report, 
    client/modules/advanced/res/templates/workflow/action-fields, 
    client/modules/advanced/res/templates/workflow/action-modals, 
    client/modules/advanced/res/templates/workflow/actions, 
    client/modules/advanced/res/templates/workflow/condition-fields, 
    client/modules/advanced/res/templates/workflow/conditions, 
    client/modules/advanced/res/templates/workflow/field-definitions, 
    client/modules/advanced/res/templates/workflow/fields/help-text/detail.tpl, 
    client/modules/advanced/res/templates/workflow/record, 
    client/modules/advanced/src/controllers/report.js, 
    client/modules/advanced/src/dynamic-handlers, 
    client/modules/advanced/src
    

    It looks like /app/code/5.6.9/application/Espo/Modules and /app/code/5.6.9/client/modules are supposed to be writable - since those are where the extension installer is attempting to write files. This seems to be confirmed by visiting the /#Admin/systemRequirements page on the same EspoCRM instance - the only failures on that page are the ones shown in the partial screenshot below, which are also paths that are in the earlier error message when trying to install the extension:
    EspoCRM System Requirements.png

    Also, per the EspoCRM Server Configuration section of the Administration guide (https://www.espocrm.com/documentation/administration/server-configuration/#user-content-required-permissions-for-unix-based-systems) :

    /application/Espo/Modules, /client/modules – should be writable the current directory (775 for the current directory, 644 for files, 755 for directories and subdirectories);"

    From some poking around through ssh and digging through /home/yellowtent and the container, it looks like these folders also aren't symlinked out to the mutable appsdata presently, which would seem to indicate to me that this might likely be most cleanly fixed with an update to the packaged app. All that said, if there's something I'm missing or have done wrong, please let me know! It's very important to get this (and soon probably another or two) EspoCRM Extension working, and I definitely don't want to have to stand up a non-cloudron app install of EspoCRM just to do so.


  • Staff

    @jimcavoli This is a bug in the packaging. Working on a fix.


  • Staff

    This should be fixed now. Have pushed an update.



  • I'm now trying to install the VoIP Integration (https://www.espocrm.com/extensions/voip-integration/) extension. It fails with a similar but potentially much more problematic message:

    Error: Permission denied: 
    starface.php
    voip-service.php
    voip.php
    

    I noticed that in the the files directory for the Advanced Pack which is installable/updatable just contains the application and client folders, with each seeming to map down to a structure that follows from the root of the codebase, through symlinks, back out to the /app/data folder before any files are present.

    The VoIP Integration package is similarly set up, save for having those three additional files that are raising the errors just inside of files. So it looks like this particular extension is trying to add these three PHP files to the root of the codebase, which is of course read-only. Any idea how we can make this work?



  • I've also reached out to EspoCRM to ensure that this is correct and the intended design on their part



  • The only thing I can think of is prepping another location in /app/data to receive those files when uploaded and giving the codebase some potentially dead-ended symlinks. I don't think that would break anything on installations without the extension, but would allow it to work once added. That said, it's a little brittle if they were to change the filenames, but I can't think of many better ways to handle it without putting the whole codebase into /app/data which definitely defeats the purpose and benefit of the packaged app.


  • Staff

    @jimcavoli Thanks!

    One idea to explore is to see if creating sym links in the root solves the problem. This way the package can come out of the box with some br0ken symlinks to support these extensions. If this is by design of the upstream app, then there is no other solution.

    (Jim & I are working on this).


  • Staff

    We released a new version that fixes this. @jimcavoli thanks for helping us fix it!


Log in to reply