2017-05-14 43 views
1

我已將文件上傳到我希望刪除的應用程序引擎,因爲它們不需要在生產環境中運行我的應用程序。從應用程序引擎中刪除文件python

我該如何刪除它們。我已經將它們包含在app.yaml的skip_files部分中。

runtime: python27 
api_version: 1 
threadsafe: true 

handlers: 
- url: /.* 
    script: main.app 

skip_files: 
- ^(.*/)?#.*#$ 
- ^(.*/)?.*~$ 
- ^(.*/)?.*\.py[co]$ 
- ^(.*/)?.*/RCS/.*$ 
- ^(.*/)?\..*$ 
- ^(.*/)?.*/node_modules/.*$ 
- ^(.*/)?.*/client_libs/.*$ 
- ^(.*/)?\.bowerrc$ 
- ^(.*/)?\.bower.json$ 
- ^(.*/)?\.gulpfile.js$ 
- ^(.*/)?\.package.json$ 
- ^(.*/)?\.requirements.txt$ 

但我在部署的文件集中看到它們。

enter image description here

回答

1

將文件放入skip_files節僅僅意味着它會被跳過,應用程序運行時。這並不意味着它會被刪除,它將顯示在 已部署的文件中,因爲它在活動服務器上。

要刪除不需要的文件:

第一: 你應該部署不包含這些文件的新版本。

第二個: 使用appspot admin console將其設置爲默認版本。

最後: 刪除舊版本。

相關問題