pmcf 4.2.0 → 4.4.0
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/README.md +3 -3
- package/package.json +1 -1
- package/src/endpoint.mjs +8 -0
- package/src/service-types.mjs +3 -0
- package/src/service.mjs +8 -1
- package/src/services/influxdb.mjs +5 -3
- package/src/services/openldap.mjs +9 -4
- package/src/services/systemd-journal-remote.mjs +4 -2
- package/types/endpoint.d.mts +2 -0
- package/types/service-types.d.mts +7 -0
- package/types/service.d.mts +1 -0
- package/types/services/influxdb.d.mts +1 -0
- package/types/services/openldap.d.mts +23 -8
- package/types/services/systemd-journal-remote.d.mts +1 -0
package/README.md
CHANGED
|
@@ -181,9 +181,9 @@ Endpoint based on http
|
|
|
181
181
|
|
|
182
182
|
### Parameters
|
|
183
183
|
|
|
184
|
-
* `service`
|
|
185
|
-
* `address`
|
|
186
|
-
* `data`
|
|
184
|
+
* `service` **Service** 
|
|
185
|
+
* `address` **any** 
|
|
186
|
+
* `data` **[object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)** 
|
|
187
187
|
|
|
188
188
|
### port
|
|
189
189
|
|
package/package.json
CHANGED
package/src/endpoint.mjs
CHANGED
|
@@ -182,6 +182,7 @@ export class UnixEndpoint extends BaseEndpoint {
|
|
|
182
182
|
constructor(service, path, data) {
|
|
183
183
|
super(service, data);
|
|
184
184
|
this.path = path;
|
|
185
|
+
this.scheme = data.scheme;
|
|
185
186
|
}
|
|
186
187
|
|
|
187
188
|
get family() {
|
|
@@ -196,6 +197,13 @@ export class UnixEndpoint extends BaseEndpoint {
|
|
|
196
197
|
return this.path;
|
|
197
198
|
}
|
|
198
199
|
|
|
200
|
+
get url()
|
|
201
|
+
{
|
|
202
|
+
if(this.scheme) {
|
|
203
|
+
return `${this.scheme}://${this.path}`;
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
|
|
199
207
|
toString() {
|
|
200
208
|
return `${this.type}:${this.family}:${this.path}`;
|
|
201
209
|
}
|
package/src/service-types.mjs
CHANGED
|
@@ -68,6 +68,9 @@ export const ServiceTypes = {
|
|
|
68
68
|
{ family: "IPv6", protocol: "tcp", port: 636, tls: true }
|
|
69
69
|
]
|
|
70
70
|
},
|
|
71
|
+
ldapi: {
|
|
72
|
+
endpoints: [{ family: "unix", scheme: "ldapi", path: "/run/ldapi" }]
|
|
73
|
+
},
|
|
71
74
|
http: {
|
|
72
75
|
endpoints: [
|
|
73
76
|
{ family: "IPv4", protocol: "tcp", port: 80, tls: false },
|
package/src/service.mjs
CHANGED
|
@@ -119,6 +119,10 @@ export class Service extends Base {
|
|
|
119
119
|
return this.host.subnets;
|
|
120
120
|
}
|
|
121
121
|
|
|
122
|
+
get url() {
|
|
123
|
+
return this.endpoint()?.url;
|
|
124
|
+
}
|
|
125
|
+
|
|
122
126
|
get services() {
|
|
123
127
|
return [this];
|
|
124
128
|
}
|
|
@@ -246,7 +250,10 @@ export class Service extends Base {
|
|
|
246
250
|
}
|
|
247
251
|
|
|
248
252
|
get systemdService() {
|
|
249
|
-
return
|
|
253
|
+
return (
|
|
254
|
+
this.extendedProperty("_systemdService") ??
|
|
255
|
+
ServiceTypes[this.type]?.systemdService
|
|
256
|
+
);
|
|
250
257
|
}
|
|
251
258
|
|
|
252
259
|
dnsRecordsForDomainName(domainName, hasSVRRecords) {
|
|
@@ -16,7 +16,7 @@ const InfluxdbServiceTypeDefinition = {
|
|
|
16
16
|
owners: ServiceTypeDefinition.owners,
|
|
17
17
|
key: "name",
|
|
18
18
|
attributes: {
|
|
19
|
-
|
|
19
|
+
metricsDisabled: {
|
|
20
20
|
externalName: "metrics-disabled",
|
|
21
21
|
...boolean_attribute_writable_true,
|
|
22
22
|
configurable: true
|
|
@@ -28,13 +28,15 @@ const InfluxdbServiceTypeDefinition = {
|
|
|
28
28
|
family: "IPv4",
|
|
29
29
|
port: 8086,
|
|
30
30
|
protocol: "tcp",
|
|
31
|
-
tls: false
|
|
31
|
+
tls: false,
|
|
32
|
+
pathname: "/"
|
|
32
33
|
},
|
|
33
34
|
{
|
|
34
35
|
family: "IPv6",
|
|
35
36
|
port: 8086,
|
|
36
37
|
protocol: "tcp",
|
|
37
|
-
tls: false
|
|
38
|
+
tls: false,
|
|
39
|
+
pathname: "/"
|
|
38
40
|
}
|
|
39
41
|
]
|
|
40
42
|
}
|
|
@@ -39,22 +39,27 @@ const OpenLDAPServiceTypeDefinition = {
|
|
|
39
39
|
...number_attribute_writable,
|
|
40
40
|
configurable: true,
|
|
41
41
|
default: 524288
|
|
42
|
+
},
|
|
43
|
+
txn_checkpoint: {
|
|
44
|
+
...string_attribute_writable,
|
|
45
|
+
configurable: true,
|
|
42
46
|
}
|
|
43
47
|
}
|
|
44
48
|
}
|
|
45
49
|
},
|
|
46
50
|
service: {
|
|
47
51
|
systemdService: "slapd.service",
|
|
48
|
-
extends: ["ldap"],
|
|
52
|
+
extends: ["ldap","ldapi"],
|
|
49
53
|
services: {
|
|
50
|
-
|
|
54
|
+
/* ldap: {
|
|
51
55
|
endpoints: [
|
|
52
56
|
{
|
|
53
57
|
family: "unix",
|
|
54
|
-
path: "/run/ldapi"
|
|
58
|
+
path: "/run/ldapi",
|
|
59
|
+
scheme: "ldapi"
|
|
55
60
|
}
|
|
56
61
|
]
|
|
57
|
-
}
|
|
62
|
+
}*/
|
|
58
63
|
}
|
|
59
64
|
}
|
|
60
65
|
};
|
|
@@ -66,13 +66,15 @@ const SystemdJournalRemoteServiceTypeDefinition = {
|
|
|
66
66
|
family: "IPv4",
|
|
67
67
|
port: 19532,
|
|
68
68
|
protocol: "tcp",
|
|
69
|
-
tls: false
|
|
69
|
+
tls: false,
|
|
70
|
+
pathname: "/"
|
|
70
71
|
},
|
|
71
72
|
{
|
|
72
73
|
family: "IPv6",
|
|
73
74
|
port: 19532,
|
|
74
75
|
protocol: "tcp",
|
|
75
|
-
tls: false
|
|
76
|
+
tls: false,
|
|
77
|
+
pathname: "/"
|
|
76
78
|
}
|
|
77
79
|
]
|
|
78
80
|
}
|
package/types/endpoint.d.mts
CHANGED
|
@@ -46,9 +46,11 @@ export class HTTPEndpoint extends BaseEndpoint {
|
|
|
46
46
|
export class UnixEndpoint extends BaseEndpoint {
|
|
47
47
|
constructor(service: any, path: any, data: any);
|
|
48
48
|
path: any;
|
|
49
|
+
scheme: any;
|
|
49
50
|
get family(): string;
|
|
50
51
|
get host(): any;
|
|
51
52
|
get address(): any;
|
|
53
|
+
get url(): string;
|
|
52
54
|
}
|
|
53
55
|
/**
|
|
54
56
|
* Endpoint with an ip port
|
package/types/service.d.mts
CHANGED
|
@@ -614,6 +614,7 @@ export class Service extends Base {
|
|
|
614
614
|
get domainName(): string;
|
|
615
615
|
get networks(): Set<any>;
|
|
616
616
|
get subnets(): Set<any>;
|
|
617
|
+
get url(): any;
|
|
617
618
|
get services(): this[];
|
|
618
619
|
get serviceTypeEndpoints(): any;
|
|
619
620
|
endpoints(filter: any): (UnixEndpoint | HTTPEndpoint | Endpoint | DomainNameEndpoint)[];
|
|
@@ -814,6 +814,28 @@ export class OpenLDAPService extends Service {
|
|
|
814
814
|
env?: string[] | string;
|
|
815
815
|
additionalValues?: object;
|
|
816
816
|
};
|
|
817
|
+
txn_checkpoint: {
|
|
818
|
+
configurable: boolean;
|
|
819
|
+
type: object;
|
|
820
|
+
isKey: boolean;
|
|
821
|
+
writable: boolean;
|
|
822
|
+
mandatory: boolean;
|
|
823
|
+
collection: boolean;
|
|
824
|
+
private?: boolean;
|
|
825
|
+
credential?: boolean;
|
|
826
|
+
persistent?: boolean;
|
|
827
|
+
depends?: string;
|
|
828
|
+
description?: string;
|
|
829
|
+
default?: any;
|
|
830
|
+
set?: Function;
|
|
831
|
+
get?: Function;
|
|
832
|
+
toInternal?: Function;
|
|
833
|
+
toExternal?: Function;
|
|
834
|
+
values?: Set<any>;
|
|
835
|
+
externalName?: string;
|
|
836
|
+
env?: string[] | string;
|
|
837
|
+
additionalValues?: object;
|
|
838
|
+
};
|
|
817
839
|
};
|
|
818
840
|
type: object;
|
|
819
841
|
isKey: boolean;
|
|
@@ -839,14 +861,7 @@ export class OpenLDAPService extends Service {
|
|
|
839
861
|
service: {
|
|
840
862
|
systemdService: string;
|
|
841
863
|
extends: string[];
|
|
842
|
-
services: {
|
|
843
|
-
ldap: {
|
|
844
|
-
endpoints: {
|
|
845
|
-
family: string;
|
|
846
|
-
path: string;
|
|
847
|
-
}[];
|
|
848
|
-
};
|
|
849
|
-
};
|
|
864
|
+
services: {};
|
|
850
865
|
};
|
|
851
866
|
};
|
|
852
867
|
DB_CONFIG: {};
|