-
-
Notifications
You must be signed in to change notification settings - Fork 13.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
plausible: 1.3.0 -> 1.4.0 #143345
plausible: 1.3.0 -> 1.4.0 #143345
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,43 +5,35 @@ | |
, glibcLocales | ||
, cacert | ||
, mkYarnModules | ||
, fetchYarnDeps | ||
, nodejs | ||
, fetchpatch | ||
, nixosTests | ||
}: | ||
|
||
let | ||
pname = "plausible"; | ||
version = "1.3.0"; | ||
version = "1.4.0"; | ||
|
||
src = fetchFromGitHub { | ||
owner = "plausible"; | ||
repo = "analytics"; | ||
rev = "v${version}"; | ||
sha256 = "03lm1f29gwwixnhgjish5bhi3m73qyp71ns2sczdnwnbhrw61zps"; | ||
sha256 = "1d31y7mwvml17w97dm5c4312n0ciq39kf4hz3g80hdzbbn72mi4q"; | ||
}; | ||
|
||
# TODO consider using `mix2nix` as soon as it supports git dependencies. | ||
mixFodDeps = beamPackages.fetchMixDeps { | ||
pname = "${pname}-deps"; | ||
inherit src version; | ||
sha256 = "1x0if0ifk272vcqjlgf097pxsw13bhwy8vs0b89l0bssx1bzygsi"; | ||
|
||
# We need ecto 3.6 as this version checks whether the database exists before | ||
# trying to create it. The creation attempt would always require super-user privileges | ||
# and since 3.6 this isn't the case anymore. | ||
patches = [ | ||
./ecto_sql-fix.patch | ||
./plausible-Bump-clickhouse_ecto-dependency-to-be-compatible-with-ecto-3.6.patch | ||
]; | ||
sha256 = "1ikcskp4gvvdprl65x1spijdc8dz6klnrnkvgy2jbk0b3d7yn1v5"; | ||
}; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Does this still work fine with the update script? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Just updated the script to make sure it works with the new version. |
||
|
||
yarnDeps = mkYarnModules { | ||
pname = "${pname}-yarn-deps"; | ||
inherit version; | ||
packageJSON = ./package.json; | ||
yarnNix = ./yarn.nix; | ||
yarnLock = ./yarn.lock; | ||
yarnNix = ./yarn.nix; | ||
preBuild = '' | ||
mkdir -p tmp/deps | ||
cp -r ${mixFodDeps}/phoenix tmp/deps/phoenix | ||
|
@@ -57,19 +49,6 @@ beamPackages.mixRelease { | |
|
||
nativeBuildInputs = [ nodejs ]; | ||
|
||
patches = [ | ||
# Allow socket-authentication against postgresql. Upstream PR is | ||
# https://github.com/plausible/analytics/pull/1052 | ||
(fetchpatch { | ||
url = "https://github.com/Ma27/analytics/commit/f2ee5892a6c3e1a861d69ed30cac43e05e9cd36f.patch"; | ||
sha256 = "sha256-JvJ7xlGw+tHtWje+jiQChVC4KTyqqdq2q+MIcOv/k1o="; | ||
}) | ||
|
||
# Ensure that `tzdata` doesn't write into its store-path | ||
# https://github.com/plausible/analytics/pull/1096, but rebased onto 1.3.0 | ||
./tzdata-rebased.patch | ||
]; | ||
|
||
passthru = { | ||
tests = { inherit (nixosTests) plausible; }; | ||
updateScript = ./update.sh; | ||
|
This file was deleted.
This file was deleted.
This file was deleted.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, whyis this not needed anymore?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My bad for not detailing a bit more.
bindsTo is just a strong form of requires, where if the required dependency stops, then the dependency stops as well. It doesn't really make sense for a setup script that just runs for several seconds (IMO). Open to discussion of course.
requiredBy, is usually never used in the configuration settings directly and is just the symetric of required.
https://www.freedesktop.org/software/systemd/man/systemd.unit.html#Mapping%20of%20unit%20properties%20to%20their%20inverses
(from the Note section).
Perhaps I read that in the wrong way. Open for discussions as well.