Bug 268601 - net/jotta-cli: jottad needs write access to etc/jottad
Summary: net/jotta-cli: jottad needs write access to etc/jottad
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Robert Clausecker
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-12-27 14:36 UTC by Vidar Karlsen
Modified: 2023-02-20 23:42 UTC (History)
3 users (show)

See Also:
trueos: maintainer-feedback+
trueos: merge-quarterly?


Attachments
Add @dir etc/jottad to pkg-plist to fix ownership (637 bytes, patch)
2022-12-27 14:36 UTC, Vidar Karlsen
no flags Details | Diff
Updated patch to port that incorporates initial patch with report (1.59 KB, patch)
2023-01-10 10:33 UTC, Trenton Schulz
trueos: maintainer-approval+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Vidar Karlsen 2022-12-27 14:36:23 UTC
Created attachment 239066 [details]
Add @dir etc/jottad to pkg-plist to fix ownership

The port creates etc/jottad as owned by root:root, and jottad does not have access to write its configuration there.

When owned by jottad:jottad, everything seems to function as advertised.

The attached patch adds the dir to pkg-plist after the @owner and @group lines to achieve this.
Comment 1 Trenton Schulz 2023-01-02 07:23:07 UTC
Comment on attachment 239066 [details]
Add @dir etc/jottad to pkg-plist to fix ownership

Yes, this patch looks correct. Thank you for pointing this out. Unfortunately, the machine I run this on had this directory early with the correct permissions, so I did not notice this issue.

Thanks again!
Comment 2 Trenton Schulz 2023-01-10 10:33:13 UTC
Created attachment 239376 [details]
Updated patch to port that incorporates initial patch with report

Updated the patch to include the port revision so that it can easily be submitted.
Comment 3 commit-hook freebsd_committer freebsd_triage 2023-02-20 23:38:48 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=6d180ad91535336621811d40456e7ad8de586f62

commit 6d180ad91535336621811d40456e7ad8de586f62
Author:     Trenton Schulz <trenton@nr.no>
AuthorDate: 2023-02-17 15:02:56 +0000
Commit:     Robert Clausecker <fuz@FreeBSD.org>
CommitDate: 2023-02-20 23:36:40 +0000

    net/jotta-cli: Fix permissions for jotta-cli

    The ownership for @LOCALBASE/etc/jottad were wrong (they need to be
    owned by jottad:jottad.

    As I had updated the portrevision, I fixed some PORTLINT issues as
    well.

    MFH:            2023Q1
    PR:             268601
    Reported by:    Vidar Karlsen <vidar@karlsen.tech>
    Approved by:    flo (mentor)
    Differential Revision: https://reviews.freebsd.org/D38685

 net/jotta-cli/Makefile  | 6 +++---
 net/jotta-cli/pkg-plist | 1 +
 2 files changed, 4 insertions(+), 3 deletions(-)
Comment 4 commit-hook freebsd_committer freebsd_triage 2023-02-20 23:41:53 UTC
A commit in branch 2023Q1 references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=e12bc14b2ae66b0b7d036f5fc2537f8961aae517

commit e12bc14b2ae66b0b7d036f5fc2537f8961aae517
Author:     Trenton Schulz <trenton@nr.no>
AuthorDate: 2023-02-17 15:02:56 +0000
Commit:     Robert Clausecker <fuz@FreeBSD.org>
CommitDate: 2023-02-20 23:40:24 +0000

    net/jotta-cli: Fix permissions for jotta-cli

    The ownership for @LOCALBASE/etc/jottad were wrong (they need to be
    owned by jottad:jottad.

    As I had updated the portrevision, I fixed some PORTLINT issues as
    well.

    MFH:            2023Q1
    PR:             268601
    Reported by:    Vidar Karlsen <vidar@karlsen.tech>
    Approved by:    flo (mentor)
    Differential Revision: https://reviews.freebsd.org/D38685

    (cherry picked from commit 6d180ad91535336621811d40456e7ad8de586f62)

 net/jotta-cli/Makefile  | 6 +++---
 net/jotta-cli/pkg-plist | 1 +
 2 files changed, 4 insertions(+), 3 deletions(-)
Comment 5 Robert Clausecker freebsd_committer freebsd_triage 2023-02-20 23:42:25 UTC
Thank you for your contribution.