@deslop/auth 0.1.1223 → 0.1.1227

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/server.js +7 -4
  2. package/package.json +2 -2
package/dist/server.js CHANGED
@@ -89006,7 +89006,7 @@ function layerKeyValueStore(directory) {
89006
89006
  const layerDataStore = unwrap$7(map$5(dataDirectory, layerKeyValueStore));
89007
89007
  const layerProtocol = mergeAll$1(layerSchemaBinary(), succeed$6(MaxBodySize)(mebibytes(10)));
89008
89008
  const layerTelemetry = unwrap$7(gen(function* () {
89009
- const name = yield* appName;
89009
+ const name = (yield* packageMetadata).name;
89010
89010
  return match$8(yield* option(String$5("OTEL_URL")), {
89011
89011
  onNone: () => empty$11,
89012
89012
  onSome: (url) => layerOtlp(`${name}-server`, url, "server")
@@ -89152,17 +89152,20 @@ function systemctl(...args) {
89152
89152
  const unitDirectory = gen(function* () {
89153
89153
  return (yield* Path$1).join(yield* String$5("HOME"), ".config", "systemd", "user");
89154
89154
  });
89155
- const install = fnUntraced(function* (name, command) {
89155
+ const install = fnUntraced(function* (name, command, options) {
89156
89156
  const fs = yield* FileSystem;
89157
89157
  const path = yield* Path$1;
89158
89158
  const home = yield* String$5("HOME");
89159
89159
  const directory = yield* unitDirectory;
89160
89160
  const unit = `deslop-${name}.service`;
89161
89161
  yield* fs.makeDirectory(directory, { recursive: true });
89162
- yield* fs.writeFileString(path.join(directory, unit), `[Unit]\nDescription=Deslop ${name}\nAfter=network-online.target\n\n[Service]\nType=simple\nEnvironment=NODE_ENV=production\nEnvironment=${systemdArgument(`PATH=${home}/.vite-plus/bin:/usr/local/bin:/usr/bin:/bin`)}\nEnvironmentFile=-${systemdArgument(`${home}/.deslop/${name}.env`)}\nExecStart=${join$2(map$8(command, systemdArgument), " ")}\nRestart=on-failure\nRestartSec=3\nUMask=0077\n\n[Install]\nWantedBy=default.target\n`, { mode: 384 });
89162
+ yield* fs.writeFileString(path.join(directory, unit), `[Unit]\nDescription=Deslop ${name}\nAfter=network-online.target\n\n[Service]\nType=simple\nEnvironment=NODE_ENV=production\nEnvironment=${systemdArgument(`PATH=${home}/.vite-plus/bin:/usr/local/bin:/usr/bin:/bin`)}\nEnvironmentFile=-${replaceAll("%", "%%")(`${home}/.deslop/${name}.env`)}\nExecStart=${join$2(map$8(command, systemdArgument), " ")}\nRestart=on-failure\nRestartSec=3\nUMask=0077\n\n[Install]\nWantedBy=default.target\n`, { mode: 384 });
89163
89163
  yield* systemctl("daemon-reload");
89164
89164
  yield* systemctl("enable", unit);
89165
- yield* systemctl("restart", unit);
89165
+ yield* systemctl(match$1(options?.restart === false, {
89166
+ onFalse: () => "restart",
89167
+ onTrue: () => "start"
89168
+ }), unit);
89166
89169
  return `${unit} installed\n`;
89167
89170
  });
89168
89171
  const installUpdates = fnUntraced(function* (name, command) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@deslop/auth",
3
- "version": "0.1.1223",
3
+ "version": "0.1.1227",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "https://github.com/MP281X/deslop",
@@ -32,5 +32,5 @@
32
32
  "engines": {
33
33
  "node": ">=26"
34
34
  },
35
- "fingerprint": "f7a1ba8a0a80a703d3f44e91a6b874930b6e69da75f5fd97727f45a86139f23f"
35
+ "fingerprint": "33c8e9ec656d6d0ecb755911d55e06fe8fda82c363e5486ab13351a45cae82ce"
36
36
  }