pmcf 2.11.0 → 2.11.2

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pmcf",
3
- "version": "2.11.0",
3
+ "version": "2.11.2",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
package/src/location.mjs CHANGED
@@ -1,4 +1,3 @@
1
- import { mkdir, copyFile } from "node:fs/promises";
2
1
  import { join } from "node:path";
3
2
  import { FileContentProvider } from "npm-pkgbuild";
4
3
  import { Owner } from "./owner.mjs";
@@ -49,10 +48,13 @@ export class Location extends Owner {
49
48
  async *preparePackages(dir) {
50
49
  const packageData = {
51
50
  dir,
52
- sources: [new FileContentProvider(dir + "/"), new FileContentProvider(
53
- { base: host.directory, pattern: "location.json" },
54
- { destination: "/etc/location/location.json" }
55
- )],
51
+ sources: [
52
+ new FileContentProvider(dir + "/"),
53
+ new FileContentProvider(
54
+ { base: this.directory, pattern: "location.json" },
55
+ { destination: "/etc/location/location.json" }
56
+ )
57
+ ],
56
58
  outputs: this.outputs,
57
59
  properties: {
58
60
  name: `${this.typeName}-${this.name}`,
@@ -142,6 +142,18 @@ export class DHCPService extends Service {
142
142
  }
143
143
  };
144
144
 
145
+ const dhcpServerDdns = {
146
+ "enable-updates": false,
147
+ "server-ip": "127.0.0.1",
148
+ "server-port": ddns.DhcpDdns.port,
149
+ /*"sender-ip": "",
150
+ "sender-port": 0,
151
+ */
152
+ "max-queue-size": 64,
153
+ "ncr-protocol": "UDP",
154
+ "ncr-format": "JSON"
155
+ };
156
+
145
157
  const subnets = new Set();
146
158
 
147
159
  for (const network of this.networks) {
@@ -178,7 +190,7 @@ export class DHCPService extends Service {
178
190
  interfaces: [...host.networkInterfaces.values()]
179
191
  .filter(ni => ni.kind !== "loopback")
180
192
  .map(ni => `${ni.name}/${ni.rawIPv4Address}`)
181
- },
193
+ },
182
194
  "multi-threading": {
183
195
  "enable-multi-threading": false
184
196
  },
@@ -212,6 +224,7 @@ export class DHCPService extends Service {
212
224
  reservations
213
225
  };
214
226
  }),
227
+ "dhcp-ddns": dhcpServerDdns,
215
228
  loggers
216
229
  }
217
230
  };
@@ -222,7 +235,7 @@ export class DHCPService extends Service {
222
235
  interfaces: [...host.networkInterfaces.values()]
223
236
  .filter(ni => ni.kind !== "loopback")
224
237
  .map(ni => `${ni.name}/${ni.rawIPv6Address}`)
225
- },
238
+ },
226
239
  "control-socket": {
227
240
  "socket-type": "unix",
228
241
  "socket-name": "/run/kea/6-ctrl-socket"
@@ -264,6 +277,7 @@ export class DHCPService extends Service {
264
277
  ]
265
278
  }
266
279
  ],
280
+ "dhcp-ddns": dhcpServerDdns,
267
281
  loggers
268
282
  }
269
283
  };