[PATCH] services: readymedia-activation: Change directory permissions to 775.

  • Done
  • quality assurance status badge
Details
2 participants
  • Ludovic Courtès
  • Sughosha
Owner
unassigned
Submitted by
Sughosha
Severity
normal

Debbugs page

Sughosha wrote 1 weeks ago
(address . guix-patches@gnu.org)(name . Sughosha)(address . sughosha@disroot.org)
c039ec9c55cefc5880a56eb48aebbd56e087e799.1741021635.git.sughosha@disroot.org
Allow users in readymedia group to write in the directory created by
readymedia-activation.

* gnu/services/upnp.scm (readymedia-activation): Change directory permissions
to 775.

Change-Id: Ifda8e4fe8594fb5a1cdf6e329a8c83551eab9c06
---
gnu/services/upnp.scm | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

Toggle diff (17 lines)
diff --git a/gnu/services/upnp.scm b/gnu/services/upnp.scm
index e5d05add28..c125c07af2 100644
--- a/gnu/services/upnp.scm
+++ b/gnu/services/upnp.scm
@@ -187,7 +187,7 @@ (define (readymedia-activation config)
(unless (file-exists? directory)
(mkdir-p/perms directory
(getpw #$%readymedia-user-account)
- #o755)))
+ #o775)))
(list #$cache-directory
#$log-directory
#$@(map readymedia-media-directory-path

base-commit: f3f09fb4a370fd0363fd216f73736164a2a29f7b
--
2.47.1
Ludovic Courtès wrote 5 days ago
(name . Sughosha)(address . sughosha@disroot.org)(address . 76717-done@debbugs.gnu.org)
87a59vsb98.fsf@gnu.org
Sughosha <sughosha@disroot.org> skribis:

Toggle quote (9 lines)
> Allow users in readymedia group to write in the directory created by
> readymedia-activation.
>
> * gnu/services/upnp.scm (readymedia-activation): Change directory permissions
> to 775.
>
> Change-Id: Ifda8e4fe8594fb5a1cdf6e329a8c83551eab9c06
> ---

Applied, thanks!
Closed
Ludovic Courtès wrote 3 days ago
(name . Sughosha)(address . sughosha@disroot.org)(address . 76717@debbugs.gnu.org)
8734fkmtgt.fsf@gnu.org
Sughosha <sughosha@disroot.org> skribis:

Toggle quote (8 lines)
> Allow users in readymedia group to write in the directory created by
> readymedia-activation.
>
> * gnu/services/upnp.scm (readymedia-activation): Change directory permissions
> to 775.
>
> Change-Id: Ifda8e4fe8594fb5a1cdf6e329a8c83551eab9c06

I noticed (but too late) that this triggers failures of the ‘readymedia’
system test:

Toggle snippet (16 lines)
PASS: ReadyMedia user exists
PASS: ReadyMedia group exists
PASS: cache directory exists
PASS: cache directory has correct ownership
/gnu/store/hz3am9anh55m4d0951wq9gqr1z7n5zas-readymedia-test-builder:1: FAIL cache directory has expected permissions
PASS: log directory exists
PASS: log directory has correct ownership
/gnu/store/hz3am9anh55m4d0951wq9gqr1z7n5zas-readymedia-test-builder:1: FAIL log directory has expected permissions
PASS: log file exists
PASS: log file has expected permissions
PASS: ReadyMedia service is running
PASS: ReadyMedia service is listening for connections
# of expected passes 10
# of unexpected failures 2


Could you send a patch adjusting the test or suggest the way forward?

Thanks, and apologies for overlooking it!

Ludo’.
Sughosha wrote 3 days ago
[PATCH] services: readymedia: Change cache and log directory permissions to 755.
(name . Ludovic Courtès)(address . ludo@gnu.org)(address . 76717@debbugs.gnu.org)(name . Sughosha)(address . sughosha@disroot.org)
d01e7af67db9c5bb74f58fac81795dac447cc172.1741662186.git.sughosha@disroot.org
Create cache directory and log directory with 755 permission, which passes
run-readymedia-test.

* gnu/services/upnp.scm (readymedia-activation): Change directory permissions
of cache-directory and log-directory to 755.

Change-Id: Iff30040c3fd52564510f66d3568dab0ef89e0449
---
gnu/services/upnp.scm | 12 ++++++++----
1 file changed, 8 insertions(+), 4 deletions(-)

Toggle diff (27 lines)
diff --git a/gnu/services/upnp.scm b/gnu/services/upnp.scm
index c125c07af24..47c32f0a1ef 100644
--- a/gnu/services/upnp.scm
+++ b/gnu/services/upnp.scm
@@ -188,10 +188,14 @@ (define (readymedia-activation config)
(mkdir-p/perms directory
(getpw #$%readymedia-user-account)
#o775)))
- (list #$cache-directory
- #$log-directory
- #$@(map readymedia-media-directory-path
- media-directories)))))))
+ (list #$@(map readymedia-media-directory-path
+ media-directories)))
+ (for-each (lambda (directory)
+ (unless (file-exists? directory)
+ (mkdir-p/perms directory
+ (getpw #$%readymedia-user-account)
+ #o755)))
+ (list #$cache-directory #$log-directory))))))
(define readymedia-service-type
(service-type

base-commit: 42773718d5d5d42137ac84826850256fd6bed606
--
2.48.1
?
Your comment

Commenting via the web interface is currently disabled.

To comment on this conversation send an email to 76717@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 76717
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch
You may also tag this issue. See list of standard tags. For example, to set the confirmed and easy tags
mumi command -t +confirmed -t +easy
Or, remove the moreinfo tag and set the help tag
mumi command -t -moreinfo -t +help