mirror of
https://github.com/SebastianWendel/nixpkgs.git
synced 2024-09-20 12:29:02 +02:00
commit
fdee2bc6c8
|
@ -15,12 +15,16 @@ nodePackages.n8n.override {
|
|||
pkgs.postgresql
|
||||
];
|
||||
|
||||
# Patch minified source with changes from https://github.com/n8n-io/n8n/pull/5052
|
||||
preRebuild = ''
|
||||
patch -p1 -i ${./fix-permissions.diff}
|
||||
'' +
|
||||
# Oracle's official package on npm is binary only (WHY?!) and doesn't provide binaries for aarch64.
|
||||
# This can supposedly be fixed by building a custom copy of the module from source, but that's way
|
||||
# too much complexity for a setup no one would ever actually run.
|
||||
#
|
||||
# NB: If you _are_ actually running n8n on Oracle on aarch64, feel free to submit a patch.
|
||||
preRebuild = lib.optionalString stdenv.isAarch64 ''
|
||||
lib.optionalString stdenv.isAarch64 ''
|
||||
rm -rf node_modules/oracledb
|
||||
'';
|
||||
|
||||
|
@ -32,7 +36,7 @@ nodePackages.n8n.override {
|
|||
};
|
||||
|
||||
meta = with lib; {
|
||||
description = "Free and open fair-code licensed node based Workflow Automation Tool";
|
||||
description = "Free and source-available fair-code licensed workflow automation tool. Easily automate tasks across different services.";
|
||||
maintainers = with maintainers; [ freezeboy k900 ];
|
||||
license = {
|
||||
fullName = "Sustainable Use License";
|
||||
|
|
28
pkgs/applications/networking/n8n/fix-permissions.diff
Normal file
28
pkgs/applications/networking/n8n/fix-permissions.diff
Normal file
|
@ -0,0 +1,28 @@
|
|||
--- a/dist/LoadNodesAndCredentials.js
|
||||
+++ b/dist/LoadNodesAndCredentials.js
|
||||
@@ -216,6 +216,7 @@
|
||||
const { types } = loader;
|
||||
this.types.nodes = this.types.nodes.concat(types.nodes);
|
||||
this.types.credentials = this.types.credentials.concat(types.credentials);
|
||||
+ let seen = new Set();
|
||||
const iconPromises = Object.entries(types).flatMap(([typeName, typesArr]) => typesArr.map((type) => {
|
||||
var _a;
|
||||
if (!((_a = type.icon) === null || _a === void 0 ? void 0 : _a.startsWith('file:')))
|
||||
@@ -226,7 +227,16 @@
|
||||
type.iconUrl = iconUrl;
|
||||
const source = path_1.default.join(dir, icon);
|
||||
const destination = path_1.default.join(constants_1.GENERATED_STATIC_DIR, iconUrl);
|
||||
- return (0, promises_1.mkdir)(path_1.default.dirname(destination), { recursive: true }).then(async () => (0, promises_1.copyFile)(source, destination));
|
||||
+ if (!seen.has(destination)) {
|
||||
+ seen.add(destination);
|
||||
+ return (0, promises_1.mkdir)(path_1.default.dirname(destination), { recursive: true }).then(async () => {
|
||||
+ await (0, promises_1.copyFile)(source, destination);
|
||||
+ await (0, promises_1.chmod)(destination, 0o644);
|
||||
+ });
|
||||
+ }
|
||||
+ else {
|
||||
+ return Promise.resolve();
|
||||
+ }
|
||||
}));
|
||||
await Promise.all(iconPromises);
|
||||
for (const nodeTypeName in loader.nodeTypes) {
|
2174
pkgs/applications/networking/n8n/node-packages.nix
generated
2174
pkgs/applications/networking/n8n/node-packages.nix
generated
File diff suppressed because it is too large
Load diff
Loading…
Reference in a new issue