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


Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Bookmarks
  • Search
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo

Cloudron Forum

Apps | Demo | Docs | Install
  1. Cloudron Forum
  2. FreeScout
  3. Failed to open stream: Permission denied

Failed to open stream: Permission denied

Scheduled Pinned Locked Moved FreeScout
13 Posts 2 Posters 76 Views 2 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • sebastienserreS Offline
    sebastienserreS Offline
    sebastienserre
    wrote last edited by
    #1

    Hello

    My issue looks the same as https://forum.cloudron.io/topic/13321/failed-to-open-stream-permission-denied-for-cache-data/7 but I don't think a solution as been provided 😞

    Jan 10 17:23:32 => Run cron tasks
    Jan 10 17:23:32 In Filesystem.php line 122:
    Jan 10 17:23:32 2026-01-10T16:23:32Z
    Jan 10 17:23:32 file_put_contents(/app/code/storage/framework/cache/data/71/e7/71e745d13645
    Jan 10 17:23:32 beba997b5011324db8ee58db0e30): Failed to open stream: Permission denied
    

    I'm running Freescout 1.8.201 and emails are not automatically fetched. I've to click on Manage > Tools Fetch Emails to get them.

    On Manage > Status I can read:

    Non-writable files found
    

    /app/code/storage/framework/cache/data/71/e7/71e745d13645beba997b5011324db8ee58db0e30
    Run the following command (read more):
    sudo chown -R www-data:www-data /app/code
    on storage/framework/cache/data/

    text alternatif

    I've tried sudo chown -R www-data:www-data /app/code but it anwsers "Read only file system"
    I've also tried sudo chmod 775 -R /app/code/ with same results.

    Do you have any idea what I can test ?

    Generate Diagnostics Data

    https://paste.cloudron.io/opebufiqal

    He/Him - Native language: French

    1 Reply Last reply
    1
    • sebastienserreS sebastienserre referenced this topic
    • sebastienserreS Offline
      sebastienserreS Offline
      sebastienserre
      wrote last edited by
      #2

      https://forum.cloudron.io/topic/14610/not-receiving-tickets-in-freescout-helpdesk-cloudron-419-errors-on-polycast-receive/5?_=1768070658349

      Rebooting mail service and then Freescout app is solving the issue.
      I will monitor to see if it's definitively fixed.

      He/Him - Native language: French

      1 Reply Last reply
      2
      • sebastienserreS Offline
        sebastienserreS Offline
        sebastienserre
        wrote last edited by
        #3

        The error just came back....

        He/Him - Native language: French

        1 Reply Last reply
        1
        • nebulonN Away
          nebulonN Away
          nebulon
          Staff
          wrote last edited by
          #4

          So /app/code is read-only in Cloudron, however /app/code/storage is linked into /app/data/, which is read-write. So the correct chown would be against /app/data/storage/ in this case. The startup code of the app does this already, which is why it works after a restart.

          Then the question remains, who changes permissions on that cache folder. Do you have some custom cron job or so which may run as root maybe? Which plugins have you installed, which could interfere here?

          1 Reply Last reply
          1
          • sebastienserreS Offline
            sebastienserreS Offline
            sebastienserre
            wrote last edited by
            #5

            Hello @nebulon
            I've a cron here:
            cloudron app cron

            Here the list of Freescout module:
            freescout module list

            In the Workflows, I only have rule like "if email is XXXX then apply tag XXXX"

            He/Him - Native language: French

            1 Reply Last reply
            1
            • nebulonN Away
              nebulonN Away
              nebulon
              Staff
              wrote last edited by
              #6

              Ah I see, that custom cron is most likely the root case then, since it runs the scheduler as root instead of www-data. Either way the package already comes with this cron job: https://git.cloudron.io/packages/freescout-app/-/blob/master/cron.sh?ref_type=heads

              So you should be fine with just removing your custom cron setting there, if I read that correctly, and that hopefully solves the issue.

              1 Reply Last reply
              0
              • sebastienserreS Offline
                sebastienserreS Offline
                sebastienserre
                wrote last edited by
                #7

                I've removed and will monitor few days .
                Thanks

                He/Him - Native language: French

                1 Reply Last reply
                1
                • sebastienserreS Offline
                  sebastienserreS Offline
                  sebastienserre
                  wrote last edited by
                  #8

                  Removed it and no emails are fetch.
                  What's strange is I'm checking the emails on the Sogo Webmail (on Cloudron) and the email is mark as read... but not available on Freescout

                  He/Him - Native language: French

                  1 Reply Last reply
                  0
                  • nebulonN Away
                    nebulonN Away
                    nebulon
                    Staff
                    wrote last edited by
                    #9

                    Have you restarted the app after removing the cron job, just to make sure the permissions are all set correctly?

                    1 Reply Last reply
                    0
                    • sebastienserreS Offline
                      sebastienserreS Offline
                      sebastienserre
                      wrote last edited by
                      #10

                      The error gone thank you @nebulon

                      I now have an issue on mails which are not fetched
                      This is now like if Cron tasks were not correctly done. The email is mark as read but not available in Freescout.

                      • Setting unread an email
                      • Visiting the URL https://example.com/system/cron/04c3f0b4a3771c3d76a2fac9a70b71a7 is fetching the unread emails.

                      and the email is in Freescout but as per Freescout

                      Cron Commands
                      
                      Make sure that you have the following line in your crontab:
                      * * * * * php /app/code/artisan schedule:run >> /dev/null 2>&1
                      Alternatively cron job can be executed by requesting the following URL every minute (this method is not recommended as some features may not work as expected, use it at your own risk):
                      https://example.com/system/cron/04c3f0b4a3771c3d76a2fac9a70b71a7 
                      

                      So I really do not know what I have to do 😞

                      He/Him - Native language: French

                      1 Reply Last reply
                      0
                      • nebulonN Away
                        nebulonN Away
                        nebulon
                        Staff
                        wrote last edited by
                        #11

                        Though this is exactly what the cronjob from the package already does. Cloudron runs that every minute. So at max it should take 1 minute for freescout to catch up on the emails.

                        You can also trigger the cloudron's cron job in the top right menu, if you open a webterminal into the app. Just to see if this fetches the mails correctly.

                        1 Reply Last reply
                        0
                        • sebastienserreS Offline
                          sebastienserreS Offline
                          sebastienserre
                          wrote last edited by
                          #12

                          yes but without the external cron no emails are fetch.

                          He/Him - Native language: French

                          1 Reply Last reply
                          0
                          • nebulonN Away
                            nebulonN Away
                            nebulon
                            Staff
                            wrote last edited by
                            #13

                            I feel there is something else happening here, since both are running the same command. Can you run the cron shipped via the package (via the webterminal) and see if it shows any errors? We use freescout for the Cloudron support ticket and no further cron schedule should be required. Do you see any errors at all (besides the permissions issues, which are to be expected if you run some parts as root and they update cache files, which is wrong in the first place)

                            1 Reply Last reply
                            0
                            Reply
                            • Reply as topic
                            Log in to reply
                            • Oldest to Newest
                            • Newest to Oldest
                            • Most Votes


                            • Login

                            • Don't have an account? Register

                            • Login or register to search.
                            • First post
                              Last post
                            0
                            • Categories
                            • Recent
                            • Tags
                            • Popular
                            • Bookmarks
                            • Search