pmcf 4.3.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 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
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pmcf",
3
- "version": "4.3.0",
3
+ "version": "4.4.0",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
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
  }
@@ -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 },
@@ -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
- ldap: {
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
  };
@@ -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
@@ -77,6 +77,13 @@ export const ServiceTypes: {
77
77
  tls: boolean;
78
78
  }[];
79
79
  };
80
+ ldapi: {
81
+ endpoints: {
82
+ family: string;
83
+ scheme: string;
84
+ path: string;
85
+ }[];
86
+ };
80
87
  http: {
81
88
  endpoints: {
82
89
  family: string;
@@ -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: {};