Storing Symfony 2 cache elsewere?

后端 未结 2 1708
小鲜肉
小鲜肉 2021-01-14 06:59

Is there a way to store symfony 2 cache (app/cache) somewhere else other than the filesystem? Memcache, S3, or something? Any built-in option?

2条回答
  •  伪装坚强ぢ
    2021-01-14 07:33

    You can use Gaufrette (https://github.com/KnpLabs/Gaufrette, https://github.com/KnpLabs/KnpGaufretteBundle) to create a virtual filesystem from almost any storage possible (APC, memory, S3, FTP, SQL db). Then set cache-dir to gaufrette://s3 for example.

提交回复
热议问题