pmcf 1.102.3 → 1.102.5
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 +2 -2
- package/src/services/dhcp.mjs +5 -8
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pmcf",
|
|
3
|
-
"version": "1.102.
|
|
3
|
+
"version": "1.102.5",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
"pkg-dir": "^8.0.0"
|
|
44
44
|
},
|
|
45
45
|
"devDependencies": {
|
|
46
|
-
"@types/node": "^22.13.
|
|
46
|
+
"@types/node": "^22.13.16",
|
|
47
47
|
"ava": "^6.2.0",
|
|
48
48
|
"c8": "^10.1.3",
|
|
49
49
|
"documentation": "^14.0.3",
|
package/src/services/dhcp.mjs
CHANGED
|
@@ -34,7 +34,8 @@ export class DHCPService extends Service {
|
|
|
34
34
|
}
|
|
35
35
|
|
|
36
36
|
async *preparePackages(dir) {
|
|
37
|
-
const
|
|
37
|
+
const network = this.network;
|
|
38
|
+
const name = this.owner.owner.name;
|
|
38
39
|
const packageData = {
|
|
39
40
|
dir,
|
|
40
41
|
sources: [new FileContentProvider(dir + "/")[Symbol.asyncIterator]()],
|
|
@@ -134,7 +135,7 @@ export class DHCPService extends Service {
|
|
|
134
135
|
const hwmap = new Map();
|
|
135
136
|
const hostNames = new Set();
|
|
136
137
|
|
|
137
|
-
for await (const { networkInterface } of
|
|
138
|
+
for await (const { networkInterface } of network.networkAddresses()) {
|
|
138
139
|
if (networkInterface.hwaddr) {
|
|
139
140
|
if (!hostNames.has(networkInterface.hostName)) {
|
|
140
141
|
hwmap.set(networkInterface.hwaddr, networkInterface);
|
|
@@ -183,14 +184,10 @@ export class DHCPService extends Service {
|
|
|
183
184
|
"option-data": [
|
|
184
185
|
{
|
|
185
186
|
name: "routers",
|
|
186
|
-
data:
|
|
187
|
+
data: network.gateway.rawAddress
|
|
187
188
|
}
|
|
188
189
|
],
|
|
189
|
-
reservations
|
|
190
|
-
{
|
|
191
|
-
"client-id": "01:11:22:33:44:55:66",
|
|
192
|
-
}
|
|
193
|
-
]*/
|
|
190
|
+
reservations
|
|
194
191
|
}
|
|
195
192
|
],
|
|
196
193
|
loggers
|