I'm building a site using the Yii framework. It's hosted on Ubuntu and I'm developing on Windows. When I upload changes to the live site (via filezilla), I need to change permissions on folders or files, upload the files, then change the permissions back. It's time consuming. Is there a way to change permission for a specific period of time, say 1 hour? So after an hour, they will change back?


You can change the permissions using a small bash script. In the beginning of your script, you place the command to change the permissions, then you use the command sleep 3600 (for an hour) and you continue the script with the commands to change permissions back.

Another way that looks better to me would be to let the permissions for normal operation and use ACL to allow the user you use for the file transfer.

  • ACL worked perfectly. Thanks for saving me lots of time:) – Mark Nov 4 '12 at 12:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.