mirror of
https://git.freebsd.org/ports.git
synced 2025-05-04 23:47:37 -04:00
mail/hydroxide: Fix rc.d script
- hydroxide does want to store some files and users were running "hydroxide auth" with normal user. Now, hydroxide user has a home directory, and it does store them there now. - Change upstream. PR: 280886
This commit is contained in:
parent
32214e6f12
commit
138d30ed37
5 changed files with 32 additions and 10 deletions
2
UIDs
2
UIDs
|
@ -326,7 +326,7 @@ _wsdd:*:370:370::0:0:Web Service Discovery Daemon:/nonexistent:/usr/sbin/nologin
|
||||||
# free: 378
|
# free: 378
|
||||||
# free: 379
|
# free: 379
|
||||||
spoofdpi:*:380:380::0:0:SpoofDPI Daemon:/nonexistent:/usr/sbin/nologin
|
spoofdpi:*:380:380::0:0:SpoofDPI Daemon:/nonexistent:/usr/sbin/nologin
|
||||||
hydroxide:*:381:381::0:0:Hydroxide Daemon:/nonexistent:/usr/sbin/nologin
|
hydroxide:*:381:381::0:0:Hydroxide Daemon:/var/db/hydroxide:/usr/sbin/nologin
|
||||||
# free: 382
|
# free: 382
|
||||||
# free: 383
|
# free: 383
|
||||||
# free: 384
|
# free: 384
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
PORTNAME= hydroxide
|
PORTNAME= hydroxide
|
||||||
DISTVERSIONPREFIX= v
|
DISTVERSIONPREFIX= v
|
||||||
DISTVERSION= 0.2.29
|
DISTVERSION= 0.2.29
|
||||||
PORTREVISION= 3
|
PORTREVISION= 4
|
||||||
CATEGORIES= mail
|
CATEGORIES= mail
|
||||||
|
|
||||||
MAINTAINER= nxjoseph@protonmail.com
|
MAINTAINER= nxjoseph@protonmail.com
|
||||||
|
@ -13,7 +13,7 @@ LICENSE_FILE= ${WRKSRC}/LICENSE
|
||||||
|
|
||||||
USES= go:modules
|
USES= go:modules
|
||||||
USE_GITHUB= yes
|
USE_GITHUB= yes
|
||||||
GH_ACCOUNT= emersion
|
GH_ACCOUNT= nxjosephofficial
|
||||||
GH_TUPLE= ProtonMail:go-crypto:v1.0.0:protonmail_go_crypto/vendor/github.com/ProtonMail/go-crypto \
|
GH_TUPLE= ProtonMail:go-crypto:v1.0.0:protonmail_go_crypto/vendor/github.com/ProtonMail/go-crypto \
|
||||||
boltdb:bolt:v1.3.1:boltdb_bolt/vendor/github.com/boltdb/bolt \
|
boltdb:bolt:v1.3.1:boltdb_bolt/vendor/github.com/boltdb/bolt \
|
||||||
cloudflare:circl:v1.3.7:cloudflare_circl/vendor/github.com/cloudflare/circl \
|
cloudflare:circl:v1.3.7:cloudflare_circl/vendor/github.com/cloudflare/circl \
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
TIMESTAMP = 1719692102
|
TIMESTAMP = 1723902839
|
||||||
SHA256 (emersion-hydroxide-v0.2.29_GH0.tar.gz) = 96f1f1cc058544365a31d9b9c64fe44073092b36f95784c044b88641849448bc
|
SHA256 (nxjosephofficial-hydroxide-v0.2.29_GH0.tar.gz) = 504732b22d97d95db73e799878fa5dc974a151b491cd4c11867970d6aadbf45e
|
||||||
SIZE (emersion-hydroxide-v0.2.29_GH0.tar.gz) = 45566
|
SIZE (nxjosephofficial-hydroxide-v0.2.29_GH0.tar.gz) = 45559
|
||||||
SHA256 (ProtonMail-go-crypto-v1.0.0_GH0.tar.gz) = 596e264d2df6beb3ec40e47286f86960845ab227cb635150ef3bd35a90a79e43
|
SHA256 (ProtonMail-go-crypto-v1.0.0_GH0.tar.gz) = 596e264d2df6beb3ec40e47286f86960845ab227cb635150ef3bd35a90a79e43
|
||||||
SIZE (ProtonMail-go-crypto-v1.0.0_GH0.tar.gz) = 333515
|
SIZE (ProtonMail-go-crypto-v1.0.0_GH0.tar.gz) = 333515
|
||||||
SHA256 (boltdb-bolt-v1.3.1_GH0.tar.gz) = b5ae498b780f535a5d308c188dee1329b3536275d29ad6758876084c0b8586a8
|
SHA256 (boltdb-bolt-v1.3.1_GH0.tar.gz) = b5ae498b780f535a5d308c188dee1329b3536275d29ad6758876084c0b8586a8
|
||||||
|
|
|
@ -27,17 +27,26 @@ esac
|
||||||
|
|
||||||
name=${name##*/}
|
name=${name##*/}
|
||||||
rcvar="${name}_enable"
|
rcvar="${name}_enable"
|
||||||
|
extra_commands="init"
|
||||||
|
|
||||||
|
init_cmd="${name}_init"
|
||||||
|
su_cmd="/usr/bin/su"
|
||||||
|
|
||||||
load_rc_config "${name}"
|
load_rc_config "${name}"
|
||||||
|
|
||||||
eval "${rcvar}=\${${rcvar}:-'NO'}"
|
eval "${rcvar}=\${${rcvar}:-'NO'}"
|
||||||
eval "_args=\${${name}_args:-''}"
|
eval "__args=\${${name}_args:-''}"
|
||||||
eval "_user=\${${name}_user:-'%%USER%%'}"
|
eval "__user=\${${name}_user:-'%%USER%%'}"
|
||||||
eval "_log=\${${name}_log:-/dev/null}"
|
eval "__log=\${${name}_log:-/dev/null}"
|
||||||
|
|
||||||
pidfile="/var/run/${name}.pid"
|
pidfile="/var/run/${name}.pid"
|
||||||
|
|
||||||
command="/usr/sbin/daemon"
|
command="/usr/sbin/daemon"
|
||||||
command_args="-P ${pidfile} -u ${_user} -f -H -o ${_log} -m 3 %%PREFIX%%/bin/hydroxide ${_args} serve"
|
command_args="-P ${pidfile} -u ${__user} -f -H -o ${__log} -m 3 %%PREFIX%%/bin/hydroxide ${__args} serve"
|
||||||
|
|
||||||
|
hydroxide_init() {
|
||||||
|
read -p "Enter mail account id: " id
|
||||||
|
${su_cmd} -m ${__user} -c "%%PREFIX%%/bin/hydroxide auth $id"
|
||||||
|
}
|
||||||
|
|
||||||
run_rc_command "$1"
|
run_rc_command "$1"
|
||||||
|
|
13
mail/hydroxide/pkg-message
Normal file
13
mail/hydroxide/pkg-message
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
[
|
||||||
|
{ type: install
|
||||||
|
message: <<EOM
|
||||||
|
You should authenticate your mail account first before using hydroxide.
|
||||||
|
To authenticate:
|
||||||
|
# service hydroxide init
|
||||||
|
and follow the prompts.
|
||||||
|
To enable/start hydroxide service:
|
||||||
|
# service hydroxide enable
|
||||||
|
# service hydroxide start
|
||||||
|
EOM
|
||||||
|
}
|
||||||
|
]
|
Loading…
Add table
Reference in a new issue