Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Separate the path where temporary files uploaded by the user are stor… #177

Conversation

linuxonrails
Copy link

Separate the path where temporary files uploaded by the user are stored in a configuration variable.

We need to save the temporary images uploaded by the files (<input wire:model="..." ...>) in a different directory than the configuration directory so that it is shared by all front-end server machines.

This change creates a new configuration variable (storagePath) that keeps the original default value, but allows the developer to change that directory to a different one with a simple change:

$ git diff config/modules/cbwire.cfc
diff --git a/config/modules/cbwire.cfc b/config/modules/cbwire.cfc
index 68ab6238d4..54fb9f0ea0 100644
--- a/config/modules/cbwire.cfc
+++ b/config/modules/cbwire.cfc
@@ -2,7 +2,8 @@ component {
 
   function configure(){
     return {
+      "storagePath": "/other/dir/by/example/tmp",
     }
   }

@grantcopley
Copy link
Collaborator

Thanks @linuxonrails! I'll pull this down today and do some testing. This will be a nice addition!

@grantcopley grantcopley changed the base branch from development to next February 20, 2025 21:28
Copy link
Collaborator

@grantcopley grantcopley left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Thanks for the added feature @linuxonrails!

I'm merging this into the next branch which means it will be a part of the 4.2.0-snapshot builds for now and included when CBWIRE 4.2 is released.

@grantcopley grantcopley merged commit 8b379f5 into coldbox-modules:next Feb 20, 2025
3 of 4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants