拇指或url别名
thumbor-aliases的Python项目详细描述
拇指或URL别名插件图片::https://travis-ci.org/bluekiri/thumbor-aliases.svg?branch=master
**thumbor_aliases**让我们创建自定义url,使用友好的url重定向您最常用的请求
。
假设您的公司决定所有的缩略图都应该转到“100x100/smart`”。
因此,如果以后需要更改它,甚至可以修改别名以指向“200x200/smart”,而不必更改应用程序代码。
拇指别名
配置
^^^^^^^
如果尚未完成,则创建您的拇指配置文件:
$thumbor config>;config.cfg
,并在社区扩展上启用**拇指或U别名**插件。这可以通过在配置文件末尾添加下一行来完成:
'thumbor_aliases',
…
]
您可以设置配置变量:``aliases_storage_file``::
aliases_storage_file=“~/your_custom_filename.yml”
yaml文件应遵循下一个格式::
alias:“url/to/redirect”
例如::
thumbnail:“100x100/smart”
header:“800x200/smart”
应用程序,让魔术发生,运行下一个命令:
$thumbor--conf=your_thumbor_config.cfg-a tc_core.app.app
**thumbor_aliases**让我们创建自定义url,使用友好的url重定向您最常用的请求
。
假设您的公司决定所有的缩略图都应该转到“100x100/smart`”。
因此,如果以后需要更改它,甚至可以修改别名以指向“200x200/smart”,而不必更改应用程序代码。
拇指别名
配置
^^^^^^^
如果尚未完成,则创建您的拇指配置文件:
$thumbor config>;config.cfg
,并在社区扩展上启用**拇指或U别名**插件。这可以通过在配置文件末尾添加下一行来完成:
…
]
您可以设置配置变量:``aliases_storage_file``::
aliases_storage_file=“~/your_custom_filename.yml”
yaml文件应遵循下一个格式::
alias:“url/to/redirect”
例如::
thumbnail:“100x100/smart”
header:“800x200/smart”
应用程序,让魔术发生,运行下一个命令:
$thumbor--conf=your_thumbor_config.cfg-a tc_core.app.app