瀏覽代碼

Set rss permissions after upgrades

Bob Mottram 8 年之前
父節點
當前提交
fa83271da7
共有 1 個檔案被更改,包括 6 行新增2 行删除
  1. 6
    2
      src/freedombone-app-rss

+ 6
- 2
src/freedombone-app-rss 查看文件

85
 }
85
 }
86
 
86
 
87
 function upgrade_rss {
87
 function upgrade_rss {
88
+    RSS_MOBILE_READER_PATH=/etc/share/ttrss-mobile
89
+
88
     if [[ $(app_is_installed rss) == "1" ]]; then
90
     if [[ $(app_is_installed rss) == "1" ]]; then
89
         function_check set_repo_commit
91
         function_check set_repo_commit
90
         set_repo_commit $RSS_READER_PATH "rss reader commit" "$RSS_READER_COMMIT" $RSS_READER_REPO
92
         set_repo_commit $RSS_READER_PATH "rss reader commit" "$RSS_READER_COMMIT" $RSS_READER_REPO
104
             exit 63452
106
             exit 63452
105
         fi
107
         fi
106
 
108
 
107
-        RSS_MOBILE_READER_PATH=/etc/share/ttrss-mobile
108
-
109
         # remove any previous install
109
         # remove any previous install
110
         if [ -d $RSS_READER_PATH/g2ttree-mobile ]; then
110
         if [ -d $RSS_READER_PATH/g2ttree-mobile ]; then
111
             if [[ $(is_completed "install_rss_mobile_reader") == "1" ]]; then
111
             if [[ $(is_completed "install_rss_mobile_reader") == "1" ]]; then
119
         function_check set_repo_commit
119
         function_check set_repo_commit
120
         set_repo_commit $RSS_MOBILE_READER_PATH "rss mobile reader commit" "$RSS_MOBILE_READER_COMMIT" $RSS_MOBILE_READER_REPO
120
         set_repo_commit $RSS_MOBILE_READER_PATH "rss mobile reader commit" "$RSS_MOBILE_READER_COMMIT" $RSS_MOBILE_READER_REPO
121
     fi
121
     fi
122
+
123
+    chown -R www-data:www-data $RSS_MOBILE_READER_PATH
124
+    chown -R www-data:www-data $RSS_READER_PATH
125
+    chmod a+x $RSS_MOBILE_READER_PATH
122
 }
126
 }
123
 
127
 
124
 function backup_local_rss {
128
 function backup_local_rss {