mirror of
https://github.com/ArchiveBox/ArchiveBox.git
synced 2026-04-25 17:16:00 +03:00
[PR #1312] [MERGED] Fallback to not chown'ing ./data/archive dir if it's a network mount that prevents ownership changes #4390
Labels
No labels
expected: maybe someday
expected: next release
expected: release after next
expected: unlikely unless contributed
good first ticket
help wanted
pull-request
scope: all users
scope: windows users
size: easy
size: hard
size: medium
size: medium
status: backlog
status: blocked
status: done
status: idea-phase
status: needs followup
status: wip
status: wontfix
touches: API/CLI/Spec
touches: configuration
touches: data/schema/architecture
touches: dependencies/packaging
touches: docs
touches: js
touches: views/replayers/html/css
why: correctness
why: functionality
why: performance
why: security
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/ArchiveBox#4390
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/ArchiveBox/ArchiveBox/pull/1312
Author: @gnattu
Created: 1/5/2024
Status: ✅ Merged
Merged: 1/6/2024
Merged by: @pirate
Base:
dev← Head:main📝 Commits (2)
bc2bfc1fix: handle archive folder permission more gracefule085b1dtry to chown everything in ./data and only fallback to avoiding ./data/archive if it fails initially📊 Changes
1 file changed (+12 additions, -5 deletions)
View changed files
📝
bin/docker_entrypoint.sh(+12 -5)📄 Description
Summary
On mounted network shares,
chmodmight be hard or impossible to do without modify the server config. However, we can ignore the archive folder because we already tested if that folder is writeable and printed warnings to the user when we failed.This PR ignores the archive folder and its contents when doing the chmod step, which is useful for mounted NFS/CIFS shares on archive folder specifically but the rest of the data folder remains a local directory. When modifying the config of the server is not an option, this can still enable users to use archivebox with network shares to store the most storage consuming part of the web archives.
This PR also modifies the warning message to be more accurately reflect the permission error is happening on the archive folder specifically, not the whole data folder.
I also noticed that there are "create archive folder if not exist" comment, but the shell script actually create the logs folder. I don't know if it is the intended behavior so I leave it as-is.
Related issues
This is a followup of #1304, providing an alternative method when modifying server config is not an option.
Changes these areas
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.