craft-scripts
craft-scripts copied to clipboard
Craft Storage Folder as a Variable
Currently, the storage folder is fixed to ${LOCAL_ROOT_PATH}"${GLOBAL_CRAFT_PATH}storage/" & ${REMOTE_ROOT_PATH}"${GLOBAL_CRAFT_PATH}storage/" which has some limitations if using atomic deployments where the storage folder is symlinked into the release folder.
This change uses the same location as before but moving this variable to the .env.sh file allowing for it to be configured to an absolute path and synced without error.
So what we did for this for atomic deployments was we just symlink'd the storage directory; would this be a feasible solution for you?
That's kinda the reason for the change. I had been symlinking uploaded assets and storage to the correct positions. I am using atomic deployments on both production and staging.
When using pull-db.sh and pull-assets.sh in my staging server the commands were failing at the mkdir command unless I pointed at the absolute location of the folders and not the symlink.
Might be a better way to handle this issue, but this was the simplest fix I could think of
Gotcha, makes sense!
Any chance this will get merged?
I haven't had time to evaluate the implications of it yet; and I'd also like to see if perhaps there isn't a way we can make this work without adding yet another variable to the config