dirien
(Engin Diri)
6월 14, 2021, 5:45오전
1
여러분 안녕하세요,
이상한 문제를 발견했습니다.
우리의 환경 설정:
Discourse: 2.8.0.beta2
S3: Minio
CDN: Myra
S3는 다음과 같이 구성되어 있습니다:
root@assets-prod-app01:~# sudo -u minio mc admin policy info minio readwrite-discourse
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"s3:ListBucketMultipartUploads",
"s3:GetBucketLocation",
"s3:ListBucket"
],
"Resource": [
"arn:aws:s3:::discourse"
]
},
{
"Effect": "Allow",
"Action": [
"s3:*"
],
"Resource": [
"arn:aws:s3:::discourse/*"
]
}
]
}
하지만 편집할 때마다 항상 다음 오류 메시지가 표시됩니다.
로그 파일에서는 다음과 같은 내용이 확인됩니다.
Aws::S3::Errors::NotImplemented (A header you provided implies functionality that is not implemented)
lib/file_store/s3_store.rb:279:in `update_ACL'
lib/file_store/s3_store.rb:209:in `update_upload_ACL'
...
고려하지 못한 설정이 있는 것인지, 아니면 Minio가 Discourse와 호환되지 않는 것일까요?
사용자들로부터 조금씩 압박을 받고 있어 도움이 되는 힌트가 있다면 알려주시면 좋겠습니다.
미리 감사합니다.
dirien
(Engin Diri)
6월 22, 2021, 4:24오전
2
이 설정이 그렇게 드문가요?
더 자세히 살펴봐야 할 부분이나 변경해야 할 사항에 대해 방향을 잡아주시면 감사하겠습니다. @Falco 현재로선 좀 막혀 있는 상태입니다…
Falco
(Falco)
6월 22, 2021, 4:55오후
3
사이트 설정 secure_uploads를 활성화하셨나요? MinIO에서는 전혀 작동하지 않습니다.
Falco
(Falco)
6월 22, 2021, 9:01오후
5
dirien
(Engin Diri)
7월 8, 2021, 5:32오전
8
안녕하세요, 혹시 아이디어가 있으신가요? 번거롭게 해서 죄송합니다…
안녕하세요,
오늘 2.8.0.beta2로 업그레이드했는데, 동일한 오류가 발생합니다:
secure_media만 선택하면 minio가 다시 작동합니다.
Falco
(Falco)
7월 8, 2021, 3:50오후
10
@pmusaraj / @martin 아래 PR로 인해 발생한 회귀(regression)로 보입니다.
master ← issue/update-upload-secure-status-on-post-revision
merged 03:32AM - 21 May 21 UTC
When uploads are created from the composer (editing or creating a post),
for si… tes with secure uploads enabled we assume security by default and
that new upload is set to secure. When the post is created, we then
check whether the post uploads _actually_ need to be secure and adjust
accordingly.
We were not doing this when revising a post, so when a new upload was
created when editing a post in a public topic, the secure status stayed
true erroneously causing issues with image previews, among other things.
해당 PR에서는 아래 커밋으로 수정된 동일한 사항이 고려되지 않았습니다.
committed 04:20PM - 25 Nov 19 UTC
In `post_creator`, the ACL update is only necessary when uploads need to be secu… red.
This should fix a regression with S3 clones that do not support updating ACLs.
따라서 post_creator는 다음과 같이 동작합니다:
그리고 models/post는:
tags_changed_raw(added: added_tags, removed: removed_tags),
post_type: Post.types[:whisper],
action_code: "tags_changed",
custom_fields: {
tags_added: added_tags,
tags_removed: removed_tags,
},
)
end
def self.tags_changed_raw(added:, removed:)
if removed.present? && added.present?
I18n.t(
"topic_tag_changed.added_and_removed",
added: tag_list_to_raw(added),
removed: tag_list_to_raw(removed),
)
elsif added.present?
I18n.t("topic_tag_changed.added", added: tag_list_to_raw(added))
elsif removed.present?
I18n.t("topic_tag_changed.removed", removed: tag_list_to_raw(removed))
1개의 좋아요
martin
(Martin Brennan)
7월 9, 2021, 12:18오전
12
성능 향상을 위해 이미 적용된 수정 사항이 있으며, 이 문제가 해결되었을 것입니다:
committed 04:15PM - 21 Jun 21 UTC
When secure uploads are enabled, editing a post with many uploads can
cause a t… imeout because the store has to be contacted for each upload.
다만, 보안 미디어가 비활성화된 경우 작업을 조기에 종료하도록 수정하겠습니다.
실제로 위와 같이 할 수 없습니다. 보안 미디어가 비활성화되었거나 게시물이 다른 카테고리로 이동된 경우, 게시물 업로드가 비보안으로 표시되도록 해야 하기 때문입니다. 대신 Discourse.store.update_upload_ACL(self)을 실행할 때 Aws::S3::Errors::NotImplemented 오류를 포착하도록 수정하겠습니다. 이렇게 하면 사설 ACL을 지원하지 않는 클라이언트에서도 문제가 발생하지 않을 것입니다.
수정: 오늘 이 수정 사항을 병합했습니다. 도움이 되길 바랍니다. FIX: Handle storage providers not implementing ACLs - Pull Request #13675 - discourse/discourse - GitHub . 또한 다음 주에 새로운 베타 버전을 출시할 예정입니다.
3개의 좋아요
Falco
(Falco)
에 닫힘
7월 12, 2021, 11:00오전
13
이 주제는 3일 후 자동으로 닫혔습니다. 더 이상 새로운 답변을 작성할 수 없습니다.