diff --git a/net/gotify-server/Makefile b/net/gotify-server/Makefile index 6a573dd89401..c1a8fa556e00 100644 --- a/net/gotify-server/Makefile +++ b/net/gotify-server/Makefile @@ -1,86 +1,85 @@ PORTNAME= gotify-server -PORTVERSION= 2.6.3 +PORTVERSION= 2.7.3 DISTVERSIONPREFIX= v -PORTREVISION= 5 CATEGORIES= net MASTER_SITES= https://github.com/mfechner/freebsd-net-gotify-server/raw/refs/heads/main/:yarn_cache DISTNAME= server DISTFILES= ${PORTNAME}-yarn-offline-cache-${DISTVERSION}${EXTRACT_SUFX}:yarn_cache MAINTAINER= mfechner@FreeBSD.org COMMENT= Simple server for sending and receiving messages WWW= https://github.com/gotify/server LICENSE= MIT BROKEN_i386= Build does not succeed (timeout in poudriere) BUILD_DEPENDS= yarn${NODEJS_SUFFIX}>=1.10.0:www/yarn${NODEJS_SUFFIX} \ -USES= go:modules,1.24 nodejs:build +USES= go:modules,1.25 nodejs:build USE_RC_SUBR= gotify_server GO_MODULE= github.com/gotify/server/v2 _BUILD_DATE= $$(date -u "+%Y-%m-%d-%H%M UTC") #GO_TARGET= ./ GO_BUILDFLAGS= -buildmode=pie -modcacherw \ -ldflags=" \ -X 'main.Version=${PORTVERSION}' \ -X 'main.Commit=${GL_TAGNAME:C/^(........).*/\1/}' \ -X 'main.BuildDate=${_BUILD_DATE}' \ -X 'main.Mode=prod'" .include .if ${OPSYS} == FreeBSD && ${OSVERSION} >= 1400000 MAKE_ENV+= NODE_OPTIONS=--openssl-legacy-provider .endif USERS= gotify GROUPS= gotify PLIST_FILES= bin/gotify-server post-patch: # setup yarnrc for offline node_modules installatio @${ECHO_CMD} 'yarn-offline-mirror "${WRKDIR}/yarn-offline-cache"' >> ${WRKSRC}/ui/.yarnrc pre-build: - @cd ${WRKSRC}/ui && ${SETENV} ${MAKE_ENV} HOME=${WRKDIR} PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=true yarn install --offline + @cd ${WRKSRC}/ui && ${SETENV} ${MAKE_ENV} HOME=${WRKDIR} PUPPETEER_SKIP_DOWNLOAD=true yarn install --offline @cd ${WRKSRC}/ui && ${SETENV} ${MAKE_ENV} yarn build #${RM} -r ${STAGEDIR}${PREFIX}/share/.cache pre-install: @${RM} ${WRKSRC}/.yarnrc do-install: @${INSTALL_PROGRAM} ${WRKDIR}/bin/gotify-server ${STAGEDIR}${PREFIX}/bin/gotify-server @${MV} ${WRKSRC}/config.example.yml ${WRKSRC}/config.yml.sample @${MKDIR} ${STAGEDIR}${ETCDIR} .for x in config.yml.sample @${CP} ${WRKSRC}/${x} ${STAGEDIR}${ETCDIR}/${x} .endfor @${MKDIR} ${STAGEDIR}/var/db/gotify post-install: @${ECHO} "@sample ${ETCDIR}/config.yml.sample" >> ${TMPPLIST} @${ECHO_CMD} "@owner gotify" >> ${TMPPLIST} @${ECHO_CMD} "@group gotify" >> ${TMPPLIST} @${ECHO_CMD} "@dir /var/db/gotify" >> ${TMPPLIST} #@${ECHO_CMD} "@dir /var/db/gotify/certs" >> ${TMPPLIST} # To update # 1. comment DISTFILES # 2. Run 'make makesum' # 3. Run 'make make-yarn-cache' # 4. Upload yarn cache # 5. Uncomment DITSFILES # 6. Run 'make makesum' make-yarn-cache: patch ${RM} -r ${WRKDIR}/yarn-offline-cache cd ${WRKSRC}/ui && ${SETENV} ${MAKE_ENV} PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=true yarn --frozen-lockfile --ignore-scripts cd ${WRKDIR} && ${TAR} -czf ${PORTNAME}-yarn-offline-cache-${DISTVERSION}${EXTRACT_SUFX} yarn-offline-cache @${ECHO_CMD} upload ${PORTNAME}-yarn-offline-cache-${DISTVERSION}${EXTRACT_SUFX} .include diff --git a/net/gotify-server/distinfo b/net/gotify-server/distinfo index 22c3abb429bd..10ed750ab2e7 100644 --- a/net/gotify-server/distinfo +++ b/net/gotify-server/distinfo @@ -1,7 +1,7 @@ -TIMESTAMP = 1748321011 -SHA256 (go/net_gotify-server/server/gotify-server-yarn-offline-cache-2.6.3.tar.gz) = 6d25f0d1d4501c79bc18067078643d80554e2839361fc795cb153fea1f8b0a55 -SIZE (go/net_gotify-server/server/gotify-server-yarn-offline-cache-2.6.3.tar.gz) = 54031121 -SHA256 (go/net_gotify-server/server/v2.6.3.mod) = f365848732e5f9711d130a4ef355c225ef0a7550b777874895a287fd9fb3be8a -SIZE (go/net_gotify-server/server/v2.6.3.mod) = 2119 -SHA256 (go/net_gotify-server/server/v2.6.3.zip) = e79d170cbbb3dcfecddb2793896186d56521a6be3dfbf8fac3ac42c831b90b9d -SIZE (go/net_gotify-server/server/v2.6.3.zip) = 728447 +TIMESTAMP = 1760251977 +SHA256 (go/net_gotify-server/server/gotify-server-yarn-offline-cache-2.7.3.tar.gz) = fb5d008a93f7ff5f63d8668401444449bfad0d6fca8a61e5d1c60de867852a59 +SIZE (go/net_gotify-server/server/gotify-server-yarn-offline-cache-2.7.3.tar.gz) = 160736290 +SHA256 (go/net_gotify-server/server/v2.7.3.mod) = bfdb293d34ee4a0c595a86df5633a3aa202b334db9c0c8dc77ab006a994a3adb +SIZE (go/net_gotify-server/server/v2.7.3.mod) = 2411 +SHA256 (go/net_gotify-server/server/v2.7.3.zip) = 84ada62b7c53e0487cf991175bb41575e476c0a04acf751adfa4e96ddefef8c3 +SIZE (go/net_gotify-server/server/v2.7.3.zip) = 589444 diff --git a/net/gotify-server/files/patch-config.example.yml b/net/gotify-server/files/patch-config.example.yml index ccfd46addd3d..cf6470cfd400 100644 --- a/net/gotify-server/files/patch-config.example.yml +++ b/net/gotify-server/files/patch-config.example.yml @@ -1,36 +1,36 @@ ---- config.example.yml.orig 1979-11-29 22:00:00 UTC +--- config.example.yml.orig 1979-11-29 23:00:00 UTC +++ config.example.yml @@ -4,7 +4,7 @@ server: server: keepaliveperiodseconds: 0 # 0 = use Go default (15s); -1 = disable keepalive; set the interval in which keepalive packets will be sent. Only change this value if you know what you are doing. listenaddr: "" # the address to bind on, leave empty to bind on all addresses. Prefix with "unix:" to create a unix socket. Example: "unix:/tmp/gotify.sock". - port: 80 # the port the HTTP server will listen on + port: 9071 # the port the HTTP server will listen on ssl: enabled: false # if https should be enabled @@ -16,7 +16,7 @@ server: letsencrypt: enabled: false # if the certificate should be requested from letsencrypt accepttos: false # if you accept the tos from letsencrypt - cache: data/certs # the directory of the cache from letsencrypt + cache: /var/db/gotify/certs # the directory of the cache from letsencrypt - hosts: # the hosts for which letsencrypt should request certificates - # - mydomain.tld - # - myotherdomain.tld -@@ -46,12 +46,12 @@ database: # for database see (configure database secti + directoryurl: # override the directory url of the ACME server + # Let's Encrypt highly recommend testing against their staging environment before using their production environment. + # Staging server has high rate limits for testing and debugging, issued certificates are not valid +@@ -50,12 +50,12 @@ database: # for database see (configure database secti database: # for database see (configure database section) dialect: sqlite3 - connection: data/gotify.db + connection: /var/db/gotify/gotify.db defaultuser: # on database creation, gotify creates an admin user name: admin # the username of the default user pass: admin # the password of the default user passstrength: 10 # the bcrypt password strength (higher = better but also slower) -uploadedimagesdir: data/images # the directory for storing uploaded images -pluginsdir: data/plugins # the directory where plugin resides +uploadedimagesdir: /var/db/gotify/data/images # the directory for storing uploaded images +pluginsdir: /var/db/gotify/data/plugins # the directory where plugin resides registration: false # enable registrations diff --git a/net/gotify-server/files/patch-config_config.go b/net/gotify-server/files/patch-config_config.go index dce728c6700b..fc561187840a 100644 --- a/net/gotify-server/files/patch-config_config.go +++ b/net/gotify-server/files/patch-config_config.go @@ -1,11 +1,11 @@ ---- config/config.go.orig 2024-10-11 14:37:05 UTC +--- config/config.go.orig 1979-11-29 23:00:00 UTC +++ config/config.go -@@ -60,7 +60,7 @@ func configFiles() []string { +@@ -61,7 +61,7 @@ func configFiles() []string { if mode.Get() == mode.TestDev { return []string{"config.yml"} } - return []string{"config.yml", "/etc/gotify/config.yml"} + return []string{"config.yml", "/usr/local/etc/gotify-server/config.yml"} } // Get returns the configuration extracted from env variables or config file. diff --git a/net/gotify-server/files/patch-ui_tsconfig.json b/net/gotify-server/files/patch-ui_tsconfig.json index 065235c0f35f..67b8c2844c69 100644 --- a/net/gotify-server/files/patch-ui_tsconfig.json +++ b/net/gotify-server/files/patch-ui_tsconfig.json @@ -1,12 +1,12 @@ ---- ui/tsconfig.json.orig 2024-10-11 13:53:39 UTC +--- ui/tsconfig.json.orig 1979-11-29 23:00:00 UTC +++ ui/tsconfig.json -@@ -38,7 +38,8 @@ +@@ -32,7 +32,8 @@ "acceptance-tests", "webpack", "jest", - "src/setupTests.ts" + "src/setupTests.ts", + "**/test/*.ts" ], "include": [ "src"