Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HTMLPurifierBundleで作成されるキャッシュファイルを削除したい #6087

Open
k-yamamura opened this issue Jan 20, 2024 · 1 comment

Comments

@k-yamamura
Copy link
Contributor

k-yamamura commented Jan 20, 2024

概要(Overview)

特定のサーバ環境にてキャッシュを削除する際に、
rm -rf var/cache を実行すると、

rm -rf var/cache/
rm: 'var/cache/prod/htmlpurifier/CSS/4.15.0,4114918a13a428a8482a8a449792a5a8747582b5,1.ser' を削除できません: 許可がありません
rm: 'var/cache/prod/htmlpurifier/HTML/4.15.0,b07be21d7969cbd4a9416a819ac8ad9943060d47,1.ser' を削除できません: 許可がありません
rm: 'var/cache/prod/htmlpurifier/URI/4.15.0,3478238e680361cd87bf880f5b3cc50a1e7abc6c,1.ser' を削除できません: 許可がありません

と表示されてhtmlpurifierで作成されたキャッシュファイルがパーミッションの関係で削除されない。
rootユーザで実行すると当然削除されるが、ユーザ関係なく削除できるようにしたい。

EC-CUBE:4.1.x、4.2.x

参考url : Exercise/HTMLPurifierBundle#22

期待する内容(Expect) or 要望(Requirement)

app/config/eccube/packages配下に、

  • exercise_html_purifier.yaml
exercise_html_purifier:
    html_profiles:
        default:
            config:
                Cache.SerializerPermissions: 0777

設定ファイルを作成すると削除されるようになるため、この設定ファイルの導入可否を検討してください。

参考url : https://github.com/Exercise/HTMLPurifierBundle#configuration

@dotani1111 dotani1111 added this to the 4.3.0 milestone Jan 22, 2024
@dotani1111
Copy link
Contributor

@k-yamamura
ありがとうございます。
私自身もこちらの問題に当たったことがあるので、導入しても良いかと思いました。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants