!NhAsaYbbgmzHtXTPQJ:funklause.de

Nix NodeJS

203 Members
58 Servers

Load older messages


SenderMessageTime
10 Nov 2023
@lily:lily.flowersLily Foster
In reply to @janne.hess:helsinki-systems.de
Full reproducer with the original files: https://github.com/dasJ/broken-npm-test
frontend-npm-deps> [2023-11-10T23:15:37Z DEBUG isahc::handler] Could not resolve host: 16.0.0-beta.8

Hmmmm it really doesn't like this and assumes it's a tarball url i think? https://github.com/dasJ/broken-npm-test/blob/8c6d8ed9b180a66a81b133f68bf467e12bcbe3be/package-lock.json#L2817

23:18:12
@lily:lily.flowersLily Fosteri'll try to look at it later and might have a fix23:18:27
@janne.hess:helsinki-systems.de@janne.hess:helsinki-systems.deah didn't spot that23:22:55
@janne.hess:helsinki-systems.de@janne.hess:helsinki-systems.destrange23:23:01
@lily:lily.flowersLily Fosteri mean if it's a genuine format npm puts stuff in, i guess we should support it23:24:45
@janne.hess:helsinki-systems.de@janne.hess:helsinki-systems.de
In reply to @lily:lily.flowers
i mean if it's a genuine format npm puts stuff in, i guess we should support it
I have no idea but I assume a very old npm does out that in. It's an internal project from another company that I'm packaging so I cannot give any more information on how that file was produced
23:37:53
@janne.hess:helsinki-systems.de@janne.hess:helsinki-systems.de* In reply to @lily:lily.flowers i mean if it's a genuine format npm puts stuff in, i guess we should support it I have no idea but I assume a very old npm does out that in. It's an internal project from another company that I'm packaging so I don't have any more information on how that file was produced23:38:09
@lily:lily.flowersLily Fosterit's package aliasing and valid syntax: https://docs.npmjs.com/cli/v10/using-npm/package-spec#aliases23:42:48
@lily:lily.flowersLily Foster do you think you could open a nixpkgs issue about it and assign to me so i don't forget? @[Janne Heß] 23:43:21
@lily:lily.flowersLily Fosterthis is where that version spec came from btw: https://github.com/vuejs/vue-cli/blob/ff24edb66361a504446a141525f9981bf34e8931/packages/%40vue/cli-service/package.json#L8323:45:32
@lily:lily.flowersLily Foster* this is where that version spec came from btw: https://github.com/vuejs/vue-cli/blob/v4.5.4/packages/%40vue/cli-service/package.json#L8323:45:47
11 Nov 2023
@szucsitg:matrix.orgszucsitg
In reply to @lily:lily.flowers
but you aren't using workspace packaging then?
Could you help me what do you mean by this? Also you mentioned that I should be not link node_modules but without it it fails on the unlink error.
05:57:31
@szucsitg:matrix.orgszucsitgI was digging more into the source code, and I noticed there is a mkYarnWorkspace this what are you referring to?08:22:08
@peter-lustig:matrix.orgpeter-lustig Okay Lily Foster I got further with my buildNpmPackage 14:48:22
@peter-lustig:matrix.orgpeter-lustigIt now produces what I want14:48:29
@peter-lustig:matrix.orgpeter-lustignow just comes the server part i guess14:52:08
@lily:lily.flowersLily Foster
In reply to @szucsitg:matrix.org
Could you help me what do you mean by this? Also you mentioned that I should be not link node_modules but without it it fails on the unlink error.
can you ping me in like 5 hours? i'm running an event at the moment, but can help later
15:46:43
@szucsitg:matrix.orgszucsitg
In reply to @lily:lily.flowers
can you ping me in like 5 hours? i'm running an event at the moment, but can help later
I appreciate your time that you are trying to help me. I'm happy to learn from you, but I won't be online for long today as it's almost 10 PM. If you can provide any advice I'll follow up on it, how I should do it properly. However besides that there's 0 documentation around mkYarnWorkspace there's not many project on GitHub that uses it. I haven't tried it yet though.
20:51:47
@peter-lustig:matrix.orgpeter-lustig

ok Lily Foster, I am now a bit confused. I somehow need nginx and the systemd service, but how does this work? This is what I have now:

"example.com" = {
          enableACME = true;
          forceSSL = true;
          root = inputs.myapp.packages.${pkgs.system}.default;
          locations."/".proxyPass = "http://localhost:5173";
        };

systemd.services.myapp = {
    wantedBy = ["multi-user.target"];
    after = ["network-online.target"];
    serviceConfig = {
      Type = "exec";
      ExecStart = "ENV_VAR1="" ENV_VAR2="" ${pkgs.nodejs_20}/bin/node build";
      WorkingDirectory = inputs.myapp.packages.${pkgs.system}.default;
      Restart = "on-failure";
    };
  };
21:49:54
@peter-lustig:matrix.orgpeter-lustigthe systemd servie runs that node build, but nginx does not21:50:24
@c0ba1t:matrix.orgCobalt
In reply to @peter-lustig:matrix.org

ok Lily Foster, I am now a bit confused. I somehow need nginx and the systemd service, but how does this work? This is what I have now:

"example.com" = {
          enableACME = true;
          forceSSL = true;
          root = inputs.myapp.packages.${pkgs.system}.default;
          locations."/".proxyPass = "http://localhost:5173";
        };

systemd.services.myapp = {
    wantedBy = ["multi-user.target"];
    after = ["network-online.target"];
    serviceConfig = {
      Type = "exec";
      ExecStart = "ENV_VAR1="" ENV_VAR2="" ${pkgs.nodejs_20}/bin/node build";
      WorkingDirectory = inputs.myapp.packages.${pkgs.system}.default;
      Restart = "on-failure";
    };
  };
Why should the nginx service run the node build command?
21:51:19
@peter-lustig:matrix.orgpeter-lustig
In reply to @c0ba1t:matrix.org
Why should the nginx service run the node build command?
that is the command I need to run the application
21:51:31
@peter-lustig:matrix.orgpeter-lustigstart the app21:51:39
@c0ba1t:matrix.orgCobaltOkay, then nginx won't run any command. Your config only describes reverse proxy that redirects all requests (for the vhost) to the (presumable) service running on port 5173.21:53:36
@c0ba1t:matrix.orgCobaltPresumably, the systemd service starts a server on localhost:5137?21:55:22
@peter-lustig:matrix.orgpeter-lustig
In reply to @c0ba1t:matrix.org
Presumably, the systemd service starts a server on localhost:5137?
yeah
21:56:36
@c0ba1t:matrix.orgCobaltOkay, then that should work. If the systems service starts you should be good to go from the NodeJS side.21:57:36
@peter-lustig:matrix.orgpeter-lustig
In reply to @c0ba1t:matrix.org
Okay, then that should work. If the systems service starts you should be good to go from the NodeJS side.
so you think what I have is correct?
21:57:52
@c0ba1t:matrix.orgCobaltMaybe? You have only posted an excerpt from an NGINX vhost config with an `example.com` domain and a systemd unit. 21:59:49
@c0ba1t:matrix.orgCobaltBut it looks correct22:00:01

Show newer messages


Back to Room ListRoom Version: 6