Bug 251663 - www/minio does not create /var/db/minio
Summary: www/minio does not create /var/db/minio
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: Steve Wills
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-12-07 09:42 UTC by Emanuel Haupt
Modified: 2020-12-14 14:43 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (swills)


Attachments
The attached patch creates and registers the directory with the appropriate uid/gid. (778 bytes, patch)
2020-12-07 09:42 UTC, Emanuel Haupt
no flags Details | Diff
patch to create db dir (830 bytes, patch)
2020-12-07 13:58 UTC, Steve Wills
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Emanuel Haupt freebsd_committer freebsd_triage 2020-12-07 09:42:46 UTC
Created attachment 220342 [details]
The attached patch creates and registers the directory with the appropriate uid/gid.

www/minio does not create /var/db/minio and therefore fails to start:

```
Dec  7 09:53:44 portjail minio[12362]: ERROR Unable to initialize backend: Unable to write to the backend
Dec  7 09:53:44 portjail minio[12362]:       > Please ensure MinIO binary has write permissions for the backend
Dec  7 09:53:44 portjail minio[12362]:       HINT:
Dec  7 09:53:44 portjail minio[12362]:         Use 'sudo chown -R minio /var/db/minio && sudo chmod u+rxw /var/db/minio' to provide sufficient permissions.
Dec  7 09:54:55 portjail minio[12408]: Exiting on signal: TERMINATED
```

The attached patch creates and registers the directory with the appropriate uid/gid.
Comment 1 Steve Wills freebsd_committer freebsd_triage 2020-12-07 13:58:04 UTC
Created attachment 220344 [details]
patch to create db dir

I think it's better to do it in the rc script. This look OK to you?
Comment 2 Emanuel Haupt freebsd_committer freebsd_triage 2020-12-07 14:10:39 UTC
Not sure how this is better but sure it's your port.
Comment 3 commit-hook freebsd_committer freebsd_triage 2020-12-14 14:40:16 UTC
A commit references this bug:

Author: swills
Date: Mon Dec 14 14:39:30 UTC 2020
New revision: 558093
URL: https://svnweb.freebsd.org/changeset/ports/558093

Log:
  www/minio: update to 2020.12.12.08.39.07 [1]

  While here, patch rc script to check for db dir and create it [2]

  PR:		251663 [2]
  Reported by:	ehaupt [2]

Changes:
  head/www/minio/Makefile
  head/www/minio/distinfo
  head/www/minio/files/minio.in
Comment 4 Steve Wills freebsd_committer freebsd_triage 2020-12-14 14:43:43 UTC
Committed, thanks for the report.