pmcf 4.8.3 → 4.9.1
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 +1 -1
- package/src/host-utils.mjs +5 -3
- package/src/host.mjs +1 -0
- package/src/services/bind.mjs +3 -4
- package/types/host.d.mts +1 -2
package/package.json
CHANGED
package/src/host-utils.mjs
CHANGED
|
@@ -21,13 +21,15 @@ export async function generateMachineInfo(host, packageData) {
|
|
|
21
21
|
|
|
22
22
|
export async function generateKnownHosts(hosts, dir) {
|
|
23
23
|
const keys = [];
|
|
24
|
-
for
|
|
24
|
+
for (const host of hosts) {
|
|
25
25
|
try {
|
|
26
26
|
const [alg, key, desc] = (await host.publicKey("ed25519")).split(/\s+/);
|
|
27
27
|
|
|
28
|
-
|
|
28
|
+
for(const domainName of host.domainNames) {
|
|
29
|
+
keys.push(`${domainName} ${alg} ${key}`);
|
|
30
|
+
}
|
|
29
31
|
|
|
30
|
-
for
|
|
32
|
+
for (const addr of host.networkAddresses(
|
|
31
33
|
na => na.networkInterface.kind !== "loopback"
|
|
32
34
|
)) {
|
|
33
35
|
keys.push(`${addr.address} ${alg} ${key}`);
|
package/src/host.mjs
CHANGED
package/src/services/bind.mjs
CHANGED
|
@@ -164,7 +164,7 @@ export class BindService extends ExtraSourceService {
|
|
|
164
164
|
|
|
165
165
|
constructor(owner, data) {
|
|
166
166
|
super(owner, data);
|
|
167
|
-
|
|
167
|
+
|
|
168
168
|
this.views = {};
|
|
169
169
|
|
|
170
170
|
for (const name of ["internal", "protected"]) {
|
|
@@ -323,8 +323,7 @@ export class BindService extends ExtraSourceService {
|
|
|
323
323
|
packageData.properties = {
|
|
324
324
|
name: `named-zones-${name}-outfacing`,
|
|
325
325
|
description: `outfacing zone definitions for ${names}`,
|
|
326
|
-
access: "private"
|
|
327
|
-
hooks: {}
|
|
326
|
+
access: "private"
|
|
328
327
|
};
|
|
329
328
|
|
|
330
329
|
yield* this.generateOutfacingDefs(sources, packageData);
|
|
@@ -345,7 +344,7 @@ export class BindService extends ExtraSourceService {
|
|
|
345
344
|
|
|
346
345
|
if (outfacingZones.length) {
|
|
347
346
|
addHook(
|
|
348
|
-
packageData
|
|
347
|
+
packageData,
|
|
349
348
|
"post_upgrade",
|
|
350
349
|
`/usr/bin/named-hostname-update ${outfacingZones
|
|
351
350
|
.map(zone => zone.id)
|
package/types/host.d.mts
CHANGED
|
@@ -254,7 +254,7 @@ export class Host extends ServiceOwner {
|
|
|
254
254
|
publicKey(type?: string): Promise<string>;
|
|
255
255
|
preparePackages(dir: any): AsyncGenerator<{
|
|
256
256
|
dir: any;
|
|
257
|
-
sources:
|
|
257
|
+
sources: any[];
|
|
258
258
|
outputs: Set<typeof import("npm-pkgbuild").OCI | typeof import("npm-pkgbuild").DOCKER>;
|
|
259
259
|
properties: {
|
|
260
260
|
name: string;
|
|
@@ -269,5 +269,4 @@ export class Host extends ServiceOwner {
|
|
|
269
269
|
}, void, unknown>;
|
|
270
270
|
}
|
|
271
271
|
import { ServiceOwner } from "pmcf";
|
|
272
|
-
import { FileContentProvider } from "npm-pkgbuild";
|
|
273
272
|
import { Base } from "pmcf";
|