taon 19.0.49 → 19.0.50

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.
Files changed (148) hide show
  1. package/browser/fesm2022/taon.mjs +60 -9
  2. package/browser/fesm2022/taon.mjs.map +1 -1
  3. package/browser/lib/endpoint-context.d.ts +6 -0
  4. package/browser/lib/models.d.ts +19 -0
  5. package/browser/package.json +1 -1
  6. package/lib/base-classes/base-subscriber.d.ts +4 -0
  7. package/lib/base-classes/base-subscriber.js +25 -0
  8. package/lib/base-classes/base-subscriber.js.map +1 -0
  9. package/lib/build-info._auto-generated_.d.ts +16 -1
  10. package/lib/build-info._auto-generated_.js +16 -1
  11. package/lib/build-info._auto-generated_.js.map +1 -1
  12. package/lib/create-context.js +15 -0
  13. package/lib/create-context.js.map +1 -1
  14. package/lib/endpoint-context.d.ts +6 -0
  15. package/lib/endpoint-context.js +36 -6
  16. package/lib/endpoint-context.js.map +1 -1
  17. package/lib/env.js +5 -1
  18. package/lib/env.js.map +1 -1
  19. package/lib/models.d.ts +19 -0
  20. package/lib/models.js +3 -0
  21. package/lib/models.js.map +1 -1
  22. package/lib/realtime/realtime-client.js +9 -0
  23. package/lib/realtime/realtime-client.js.map +1 -1
  24. package/lib/realtime/realtime-server.js +1 -4
  25. package/lib/realtime/realtime-server.js.map +1 -1
  26. package/lib/realtime/realtime-strategy/realtime-abstract-mock.d.ts +10 -0
  27. package/lib/realtime/realtime-strategy/realtime-abstract-mock.js +214 -0
  28. package/lib/realtime/realtime-strategy/realtime-abstract-mock.js.map +1 -0
  29. package/lib/realtime/realtime-strategy/realtime-strategy-ipc-models/index.d.ts +0 -0
  30. package/lib/realtime/realtime-strategy/realtime-strategy-ipc-models/index.js +5 -0
  31. package/lib/realtime/realtime-strategy/realtime-strategy-ipc-models/index.js.map +1 -0
  32. package/lib/realtime/realtime-strategy/realtime-strategy-ipc-models/realtime-strategy-ipc-main-namespace.d.ts +22 -0
  33. package/lib/realtime/realtime-strategy/realtime-strategy-ipc-models/realtime-strategy-ipc-main-namespace.js +139 -0
  34. package/lib/realtime/realtime-strategy/realtime-strategy-ipc-models/realtime-strategy-ipc-main-namespace.js.map +1 -0
  35. package/lib/realtime/realtime-strategy/realtime-strategy-ipc-models/realtime-strategy-ipc-main-wrapper.d.ts +16 -0
  36. package/lib/realtime/realtime-strategy/realtime-strategy-ipc-models/realtime-strategy-ipc-main-wrapper.js +68 -0
  37. package/lib/realtime/realtime-strategy/realtime-strategy-ipc-models/realtime-strategy-ipc-main-wrapper.js.map +1 -0
  38. package/lib/realtime/realtime-strategy/realtime-strategy-ipc-models/realtime-strategy-ipc-renderer-namespace.d.ts +10 -0
  39. package/lib/realtime/realtime-strategy/realtime-strategy-ipc-models/realtime-strategy-ipc-renderer-namespace.js +56 -0
  40. package/lib/realtime/realtime-strategy/realtime-strategy-ipc-models/realtime-strategy-ipc-renderer-namespace.js.map +1 -0
  41. package/lib/realtime/realtime-strategy/realtime-strategy-ipc-models/realtime-strategy-ipc-renderer-wrapper.d.ts +10 -0
  42. package/lib/realtime/realtime-strategy/realtime-strategy-ipc-models/realtime-strategy-ipc-renderer-wrapper.js +50 -0
  43. package/lib/realtime/realtime-strategy/realtime-strategy-ipc-models/realtime-strategy-ipc-renderer-wrapper.js.map +1 -0
  44. package/lib/realtime/realtime-strategy/realtime-strategy-ipc-models/realtime-strategy-ipc.models.d.ts +13 -0
  45. package/lib/realtime/realtime-strategy/realtime-strategy-ipc-models/realtime-strategy-ipc.models.js +3 -0
  46. package/lib/realtime/realtime-strategy/realtime-strategy-ipc-models/realtime-strategy-ipc.models.js.map +1 -0
  47. package/lib/realtime/realtime-strategy/realtime-strategy-mock-models/index.d.ts +2 -0
  48. package/lib/realtime/realtime-strategy/realtime-strategy-mock-models/index.js +6 -0
  49. package/lib/realtime/realtime-strategy/realtime-strategy-mock-models/index.js.map +1 -0
  50. package/lib/realtime/realtime-strategy/realtime-strategy-mock-models/realtime-strategy-mock-client.d.ts +16 -0
  51. package/lib/realtime/realtime-strategy/realtime-strategy-mock-models/realtime-strategy-mock-client.js +54 -0
  52. package/lib/realtime/realtime-strategy/realtime-strategy-mock-models/realtime-strategy-mock-client.js.map +1 -0
  53. package/lib/realtime/realtime-strategy/realtime-strategy-mock-models/realtime-strategy-mock-namespaces.d.ts +17 -0
  54. package/lib/realtime/realtime-strategy/realtime-strategy-mock-models/realtime-strategy-mock-namespaces.js +52 -0
  55. package/lib/realtime/realtime-strategy/realtime-strategy-mock-models/realtime-strategy-mock-namespaces.js.map +1 -0
  56. package/lib/realtime/realtime-strategy/realtime-strategy-mock-models/realtime-strategy-mock-server.d.ts +11 -0
  57. package/lib/realtime/realtime-strategy/realtime-strategy-mock-models/realtime-strategy-mock-server.js +39 -0
  58. package/lib/realtime/realtime-strategy/realtime-strategy-mock-models/realtime-strategy-mock-server.js.map +1 -0
  59. package/lib/realtime/realtime-strategy/realtime-strategy-mock-models/realtime-strategy-mock-socket.d.ts +13 -0
  60. package/lib/realtime/realtime-strategy/realtime-strategy-mock-models/realtime-strategy-mock-socket.js +46 -0
  61. package/lib/realtime/realtime-strategy/realtime-strategy-mock-models/realtime-strategy-mock-socket.js.map +1 -0
  62. package/lib/realtime/realtime-strategy/realtime-strategy-mock-models/realtime-strategy-mock.models.d.ts +11 -0
  63. package/lib/realtime/realtime-strategy/realtime-strategy-mock-models/realtime-strategy-mock.models.js +3 -0
  64. package/lib/realtime/realtime-strategy/realtime-strategy-mock-models/realtime-strategy-mock.models.js.map +1 -0
  65. package/lib/storage.d.ts +1 -1
  66. package/lib/storage.js +5 -1
  67. package/lib/storage.js.map +1 -1
  68. package/lib/ui/directives/firedev-inject-html.directive.d.ts +6 -0
  69. package/lib/ui/directives/firedev-long-press.directive.d.ts +22 -0
  70. package/lib/ui/directives/index.d.ts +3 -0
  71. package/lib/ui/directives/index.js +5 -0
  72. package/lib/ui/directives/index.js.map +1 -0
  73. package/lib/ui/directives/safe.pipe.d.ts +7 -0
  74. package/lib/ui/directives/taon-inject-html.directive.d.ts +6 -0
  75. package/lib/ui/directives/taon-long-press.directive.d.ts +22 -0
  76. package/lib/ui/directives/view-mode.d.ts +5 -0
  77. package/lib/ui/directives/view-mode.js +10 -0
  78. package/lib/ui/directives/view-mode.js.map +1 -0
  79. package/lib/ui/index.js +2 -2
  80. package/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/index.d.ts +2 -0
  81. package/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/index.js +5 -0
  82. package/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/index.js.map +1 -0
  83. package/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/taon-admin-edit-mode.component.d.ts +29 -0
  84. package/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/taon-admin-edit-mode.module.d.ts +2 -0
  85. package/lib/ui/taon-admin-mode-configuration/components/taon-db-admin/index.d.ts +1 -0
  86. package/lib/ui/taon-admin-mode-configuration/components/taon-db-admin/index.js +5 -0
  87. package/lib/ui/taon-admin-mode-configuration/components/taon-db-admin/index.js.map +1 -0
  88. package/lib/ui/taon-admin-mode-configuration/components/taon-db-admin/taon-db-admin.component.d.ts +8 -0
  89. package/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/index.d.ts +2 -0
  90. package/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/index.js +5 -0
  91. package/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/index.js.map +1 -0
  92. package/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/taon-file-general-opt.component.d.ts +13 -0
  93. package/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/taon-file-general-opt.module.d.ts +2 -0
  94. package/lib/ui/taon-admin-mode-configuration/index.js +2 -2
  95. package/lib/ui/taon-admin-mode-configuration/models/taon-admin-mode-tabs.d.ts +5 -0
  96. package/lib/ui/taon-admin-mode-configuration/models/taon-admin-mode-tabs.js +3 -0
  97. package/lib/ui/taon-admin-mode-configuration/models/taon-admin-mode-tabs.js.map +1 -0
  98. package/lib/ui/taon-admin-mode-configuration/taon-admin-control.service.d.ts +14 -0
  99. package/lib/ui/taon-admin-mode-configuration/taon-admin-mode-configuration.component.d.ts +43 -0
  100. package/lib/ui/taon-admin-mode-configuration/taon-admin-mode-configuration.module.d.ts +2 -0
  101. package/lib/ui/taon-admin-mode-configuration/taon-admin.models.d.ts +5 -0
  102. package/lib/ui/taon-admin-mode-configuration/taon-admin.models.js +3 -0
  103. package/lib/ui/taon-admin-mode-configuration/taon-admin.models.js.map +1 -0
  104. package/lib/ui/taon-full-material.module.d.ts +5 -0
  105. package/lib/ui/taon-github-fork-me-corner/index.d.ts +2 -0
  106. package/lib/ui/taon-github-fork-me-corner/index.js +5 -0
  107. package/lib/ui/taon-github-fork-me-corner/index.js.map +1 -0
  108. package/lib/ui/taon-github-fork-me-corner/taon-github-fork-me-corner.component.d.ts +3 -0
  109. package/lib/ui/taon-github-fork-me-corner/taon-github-fork-me-corner.module.d.ts +2 -0
  110. package/lib/ui/taon-github-fork-me-ribbon/index.d.ts +2 -0
  111. package/lib/ui/taon-github-fork-me-ribbon/index.js +5 -0
  112. package/lib/ui/taon-github-fork-me-ribbon/index.js.map +1 -0
  113. package/lib/ui/taon-github-fork-me-ribbon/taon-github-fork-me-ribbon.component.d.ts +3 -0
  114. package/lib/ui/taon-github-fork-me-ribbon/taon-github-fork-me-ribbon.module.d.ts +2 -0
  115. package/lib/ui/taon-notifications/index.d.ts +4 -0
  116. package/lib/ui/taon-notifications/index.js +24 -0
  117. package/lib/ui/taon-notifications/index.js.map +1 -0
  118. package/lib/ui/taon-notifications/taon-notifications.component.d.ts +9 -0
  119. package/lib/ui/taon-notifications/taon-notifications.models.d.ts +6 -0
  120. package/lib/ui/taon-notifications/taon-notifications.models.js +5 -0
  121. package/lib/ui/taon-notifications/taon-notifications.models.js.map +1 -0
  122. package/lib/ui/taon-notifications/taon-notifications.module.d.ts +2 -0
  123. package/lib/ui/taon-notifications/taon-notifications.service.d.ts +11 -0
  124. package/lib/ui/taon-progress-bar/index.d.ts +2 -0
  125. package/lib/ui/taon-progress-bar/index.js +5 -0
  126. package/lib/ui/taon-progress-bar/index.js.map +1 -0
  127. package/lib/ui/taon-progress-bar/taon-progress-bar.component.d.ts +13 -0
  128. package/lib/ui/taon-progress-bar/taon-progress-bar.module.d.ts +2 -0
  129. package/lib/ui/taon-session-passcode/index.d.ts +1 -0
  130. package/lib/ui/taon-session-passcode/index.js +5 -0
  131. package/lib/ui/taon-session-passcode/index.js.map +1 -0
  132. package/lib/ui/taon-session-passcode/taon-session-passcode.component.d.ts +35 -0
  133. package/lib/ui/taon-table/index.d.ts +2 -0
  134. package/lib/ui/taon-table/index.js +5 -0
  135. package/lib/ui/taon-table/index.js.map +1 -0
  136. package/lib/ui/taon-table/taon-table.component.d.ts +34 -0
  137. package/lib/ui/taon-table/taon-table.module.d.ts +2 -0
  138. package/lib/ui/taon.models.d.ts +11 -0
  139. package/lib/ui/taon.models.js +3 -0
  140. package/lib/ui/taon.models.js.map +1 -0
  141. package/lib/ui/toan-full-material.module.d.ts +2 -0
  142. package/package.json +1 -1
  143. package/tmp-environment.json +43 -0
  144. package/websql/fesm2022/taon.mjs +63 -9
  145. package/websql/fesm2022/taon.mjs.map +1 -1
  146. package/websql/lib/endpoint-context.d.ts +6 -0
  147. package/websql/lib/models.d.ts +19 -0
  148. package/websql/package.json +1 -1
@@ -59,6 +59,10 @@ export declare class EndpointContext {
59
59
  get logFramework(): boolean;
60
60
  get logDb(): boolean;
61
61
  get logMigrations(): boolean;
62
+ /**
63
+ * Inside docker there is not need for https secure server
64
+ */
65
+ private isRunningInsideDocker;
62
66
  constructor(originalConfig: Models.ContextOptions<any, any, any, any, any, any, any>, configFn: (env: any) => Models.ContextOptions<any, any, any, any, any, any, any>);
63
67
  init(options?: {
64
68
  initFromRecrusiveContextResovle?: boolean;
@@ -102,6 +106,7 @@ export declare class EndpointContext {
102
106
  reinitControllers(): Promise<void>;
103
107
  initClasses(): Promise<void>;
104
108
  isActiveOn(classInstance: object): boolean;
109
+ get frontendHostUri(): URL;
105
110
  get uri(): URL;
106
111
  get uriPort(): string | undefined;
107
112
  get uriProtocol(): string | undefined;
@@ -134,6 +139,7 @@ export declare class EndpointContext {
134
139
  * ipc/udp needs this
135
140
  */
136
141
  get contextName(): string;
142
+ get activeContext(): string | null;
137
143
  get appId(): string;
138
144
  get publicAssets(): {
139
145
  serverPath: string;
@@ -85,10 +85,21 @@ export declare namespace Models {
85
85
  appId?: string;
86
86
  contextName: string;
87
87
  /**
88
+ * if defined and different from contextName
89
+ * - context will NOT be initialized
90
+ */
91
+ activeContext?: string | null;
92
+ /**
93
+ * IMPORTANT! provide full url that starts with http:// or https://
88
94
  * host/port for initing backend server
89
95
  */
90
96
  host?: string;
91
97
  /**
98
+ * Needs to be specified in docker environment only
99
+ */
100
+ hostPortNumber?: number;
101
+ /**
102
+ * IMPORTANT! provide full url that starts with http:// or https://
92
103
  * frontend host only needed when we are
93
104
  * using withCredentials for axios
94
105
  * and session cookie
@@ -96,6 +107,11 @@ export declare namespace Models {
96
107
  */
97
108
  frontendHost?: string;
98
109
  /**
110
+ * Needs to be specified in docker environment only
111
+ */
112
+ frontendHostPortNumber?: number;
113
+ /**
114
+ * IMPORTANT! provide full url that starts with http:// or https://
99
115
  * backend way of communication
100
116
  * between taon backends/processes
101
117
  */
@@ -143,7 +159,10 @@ export declare namespace Models {
143
159
  class MethodConfig {
144
160
  methodName: string;
145
161
  /**
162
+ * @deprecated don't use in production - keep stuff encapsulated
146
163
  * path is global in express app
164
+ * ! BE CAREFUL ! global path IS NOT GLOBAL inside dockerized app
165
+ * (/api/contextName is automatically added to global path in docker)
147
166
  */
148
167
  global?: boolean;
149
168
  /**
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "taon/browser",
3
- "version": "19.0.49",
3
+ "version": "19.0.50",
4
4
  "module": "fesm2022/taon.mjs",
5
5
  "typings": "index.d.ts",
6
6
  "exports": {
@@ -0,0 +1,4 @@
1
+ import { BaseInjector } from './base-injector';
2
+ export declare abstract class BaseSubscriber<Entity = any> extends BaseInjector {
3
+ protected __trigger_event__(eventName: keyof Entity): void;
4
+ }
@@ -0,0 +1,25 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.BaseSubscriber = void 0;
4
+ var tslib_1 = require("tslib");
5
+ var base_injector_1 = require("./base-injector");
6
+ var subscriber_decorator_1 = require("../decorators/classes/subscriber-decorator");
7
+ var BaseSubscriber = /** @class */ (function (_super) {
8
+ tslib_1.__extends(BaseSubscriber, _super);
9
+ function BaseSubscriber() {
10
+ return _super !== null && _super.apply(this, arguments) || this;
11
+ }
12
+ BaseSubscriber.prototype.__trigger_event__ = function (eventName) {
13
+ var ctx = this.__endpoint_context__;
14
+ console.log('Trigger event', eventName, ctx);
15
+ // ctx.realtimeServer.triggerCustomEvent/
16
+ };
17
+ BaseSubscriber = tslib_1.__decorate([
18
+ (0, subscriber_decorator_1.TaonSubscriber)({
19
+ className: 'BaseSubscriber',
20
+ })
21
+ ], BaseSubscriber);
22
+ return BaseSubscriber;
23
+ }(base_injector_1.BaseInjector));
24
+ exports.BaseSubscriber = BaseSubscriber;
25
+ //# sourceMappingURL=base-subscriber.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"base-subscriber.js","sourceRoot":"","sources":[""],"names":[],"mappings":";;;;AAWA,iDAA+C;AAC/C,mFAA4E;AAK5E;IAA2D,0CAAY;IAAvE;;IAMA,CAAC;IALW,0CAAiB,GAA3B,UAA4B,SAAuB;QACjD,IAAM,GAAG,GAAG,IAAI,CAAC,oBAAoB,CAAC;QACtC,OAAO,CAAC,GAAG,CAAC,eAAe,EAAE,SAAS,EAAE,GAAG,CAAC,CAAC;QAC7C,yCAAyC;IAC3C,CAAC;IALmB,cAAc;QAHnC,IAAA,qCAAc,EAAC;YACd,SAAS,EAAE,gBAAgB;SAC5B,CAAC;OACoB,cAAc,CAMnC;IAAD,qBAAC;CAAA,AAND,CAA2D,4BAAY,GAMtE;AANqB,wCAAc"}
@@ -1,5 +1,20 @@
1
+ /**
2
+ * Autogenerated by current cli tool
3
+ */
1
4
  export declare const BUILD_FRAMEWORK_CLI_NAME = "tnp";
5
+ /**
6
+ * This value can be change in taon.jsonc (appId)
7
+ */
2
8
  export declare const APP_ID = "dev.taon.app";
9
+ /**
10
+ * Autogenerated by current cli tool
11
+ */
3
12
  export declare const BUILD_BASE_HREF = "";
13
+ /**
14
+ * This value can be change in taon.jsonc (overrideNpmName)
15
+ */
4
16
  export declare const PROJECT_NPM_NAME = "taon";
5
- export declare const CURRENT_PACKAGE_VERSION = "19.0.49";
17
+ /**
18
+ * Autogenerated by current cli tool. Use *tnp release* to bump version.
19
+ */
20
+ export declare const CURRENT_PACKAGE_VERSION = "19.0.50";
@@ -2,10 +2,25 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.CURRENT_PACKAGE_VERSION = exports.PROJECT_NPM_NAME = exports.BUILD_BASE_HREF = exports.APP_ID = exports.BUILD_FRAMEWORK_CLI_NAME = void 0;
4
4
  // THIS FILE IS GENERATED - DO NOT MODIFY
5
+ /**
6
+ * Autogenerated by current cli tool
7
+ */
5
8
  exports.BUILD_FRAMEWORK_CLI_NAME = 'tnp';
9
+ /**
10
+ * This value can be change in taon.jsonc (appId)
11
+ */
6
12
  exports.APP_ID = 'dev.taon.app';
13
+ /**
14
+ * Autogenerated by current cli tool
15
+ */
7
16
  exports.BUILD_BASE_HREF = '';
17
+ /**
18
+ * This value can be change in taon.jsonc (overrideNpmName)
19
+ */
8
20
  exports.PROJECT_NPM_NAME = 'taon';
9
- exports.CURRENT_PACKAGE_VERSION = '19.0.49';
21
+ /**
22
+ * Autogenerated by current cli tool. Use *tnp release* to bump version.
23
+ */
24
+ exports.CURRENT_PACKAGE_VERSION = '19.0.50';
10
25
  // THIS FILE IS GENERATED - DO NOT MODIFY
11
26
  //# sourceMappingURL=build-info._auto-generated_.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"build-info._auto-generated_.js","sourceRoot":"","sources":[""],"names":[],"mappings":";;;AAAA,yCAAyC;AAC5B,QAAA,wBAAwB,GAAG,KAAK,CAAC;AACjC,QAAA,MAAM,GAAG,cAAc,CAAC;AACxB,QAAA,eAAe,GAAG,EAAE,CAAC;AACrB,QAAA,gBAAgB,GAAG,MAAM,CAAC;AAC1B,QAAA,uBAAuB,GAAG,SAAS,CAAC;AACjD,yCAAyC"}
1
+ {"version":3,"file":"build-info._auto-generated_.js","sourceRoot":"","sources":[""],"names":[],"mappings":";;;AAAA,yCAAyC;AACzC;;GAEG;AACU,QAAA,wBAAwB,GAAG,KAAK,CAAC;AAC9C;;GAEG;AACU,QAAA,MAAM,GAAG,cAAc,CAAC;AACrC;;GAEG;AACU,QAAA,eAAe,GAAG,EAAE,CAAC;AAClC;;GAEG;AACU,QAAA,gBAAgB,GAAG,MAAM,CAAC;AACvC;;GAEG;AACU,QAAA,uBAAuB,GAAG,SAAS,CAAC;AACjD,yCAAyC"}
@@ -23,6 +23,11 @@ exports.createContextTemplate = createContextTemplate;
23
23
  */
24
24
  const createContext = (configFn) => {
25
25
  let config = configFn({});
26
+ // console.log(
27
+ // `
28
+ // [Taon] Creating context ${config.contextName}...`,
29
+ // {config},
30
+ // );
26
31
  const endpointContextRef = new endpoint_context_1.EndpointContext(config, configFn);
27
32
  const res = {
28
33
  //#region types
@@ -123,6 +128,16 @@ const createContext = (configFn) => {
123
128
  return await new Promise(async (resolve, reject) => {
124
129
  //#region init in set timeout
125
130
  setTimeout(async () => {
131
+ if (lib_1.UtilsOs.isRunningInDocker()) {
132
+ const activeContext = config?.activeContext || null;
133
+ if (lib_1._.isString(activeContext) &&
134
+ activeContext !== '' &&
135
+ activeContext !== config?.contextName) {
136
+ console.warn(`[taon] Context ${endpointContextRef.contextName} is not active context, skipping initialization.`);
137
+ resolve(endpointContextRef);
138
+ return;
139
+ }
140
+ }
126
141
  await endpointContextRef.init({
127
142
  ...overrideOptions,
128
143
  });
@@ -1 +1 @@
1
- {"version":3,"file":"create-context.js","sourceRoot":"","sources":[""],"names":[],"mappings":";;;AAAA,iBAAiB;AACjB,sCAAgD;AAEhD,yDAAqD;AAErD,KAAK;AACL,YAAY;AAEZ;;;;GAIG;AACI,MAAM,qBAAqB,GAAG,CAWnC,QAUC,EACD,EAAE;IACF,OAAO,GAAG,EAAE;QACV,OAAO,IAAA,qBAAa,EAQlB,QAAQ,CAAC,CAAC;IACd,CAAC,CAAC;AACJ,CAAC,CAAC;AAlCW,QAAA,qBAAqB,yBAkChC;AAEF;;;GAGG;AACI,MAAM,aAAa,GAAG,CAW3B,QAUC,EACD,EAAE;IACF,IAAI,MAAM,GAAG,QAAQ,CAAC,EAAE,CAAC,CAAC;IAE1B,MAAM,kBAAkB,GAAG,IAAI,kCAAe,CAAC,MAAM,EAAE,QAAQ,CAAC,CAAC;IAEjE,MAAM,GAAG,GAAG;QACV,eAAe;QACf,KAAK,EAAE;YACL,qBAAqB;YACrB,mBAAmB;YACnB,4BAA4B;YAC5B,KAAK;YACL,4CAA4C;YAC5C,mDAAmD;YACnD,2CAA2C;YAC3C,2CAA2C;YAC3C,oEAAoE;YACpE,0DAA0D;YAC1D,4CAA4C;YAC5C,+CAA+C;YAC/C,8BAA8B;YAC9B,QAAQ;YACR,MAAM;YACN,qEAAqE;YACrE,KAAK;YACL,YAAY;YACZ,IAAI,WAAW;gBACb,OAAO,MAAM,CAAC,WAAkB,CAAC,CAAC,sDAAsD;YAC1F,CAAC;YACD,IAAI,YAAY;gBACd,OAAO,MAAM,CAAC,YAAmB,CAAC,CAAC,sDAAsD;YAC3F,CAAC;YACD,IAAI,SAAS;gBACX,OAAO,MAAM,CAAC,SAAgB,CAAC,CAAC,sDAAsD;YACxF,CAAC;YACD,IAAI,WAAW;gBACb,OAAO,MAAM,CAAC,WAAkB,CAAC,CAAC,sDAAsD;YAC1F,CAAC;YACD,IAAI,UAAU;gBACZ,OAAO,MAAM,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oBAC9C,+BAA+B;oBAC/B,uFAAuF;oBACvF,8BAA8B;oBAC9B,gFAAgF;oBAChF,8CAA8C;oBAC9C,mDAAmD;oBACnD,0BAA0B;oBAC1B,QAAQ;oBACR,iDAAiD;oBAEjD,4FAA4F;oBAC5F,IAAI;oBACJ,YAAY;oBAEZ,IAAI,kBAAkB,CAAC,gBAAgB,EAAE,CAAC;wBACxC,MAAM,kBAAkB,CAAC,YAAY,CAAC,4BAA4B,EAAE,CAAC;oBACvE,CAAC;yBAAM,IAAI,kBAAkB,CAAC,8BAA8B,EAAE,CAAC;wBAC7D,MAAM,kBAAkB,CAAC,YAAY,CAAC,0BAA0B,CAC9D,kBAAkB,CAAC,8BAA8B,CAClD,CAAC;oBACJ,CAAC;yBAAM,CAAC;wBACN,MAAM,kBAAkB,CAAC,YAAY,CAAC,4BAA4B,EAAE,CAAC;oBACvE,CAAC;oBAED,OAAO,CAAC,kBAAkB,CAAC,CAAC;gBAC9B,CAAC,CAAC,CAAC;gBACH,YAAY;YACd,CAAC,CAAC,CAAC;QACL,CAAC;QACD;;;WAGG;QACH,IAAI,QAAQ;YACV,OAAO;gBACL,IAAI,MAAM;oBACR,OAAO,kBAAkB,CAAC,cAAc,CAAC;gBAC3C,CAAC;gBACD,IAAI,MAAM;oBACR,OAAO,kBAAkB,CAAC,cAAc,CAAC;gBAC3C,CAAC;aACF,CAAC;QACJ,CAAC;KACF,CAAC;IACF,OAAO,GAAG,CAAC;AACb,CAAC,CAAC;AAvPW,QAAA,aAAa,iBAuPxB"}
@@ -61,6 +61,10 @@ export declare class EndpointContext {
61
61
  get logFramework(): boolean;
62
62
  get logDb(): boolean;
63
63
  get logMigrations(): boolean;
64
+ /**
65
+ * Inside docker there is not need for https secure server
66
+ */
67
+ private isRunningInsideDocker;
64
68
  constructor(originalConfig: Models.ContextOptions<any, any, any, any, any, any, any>, configFn: (env: any) => Models.ContextOptions<any, any, any, any, any, any, any>);
65
69
  init(options?: {
66
70
  initFromRecrusiveContextResovle?: boolean;
@@ -104,6 +108,7 @@ export declare class EndpointContext {
104
108
  reinitControllers(): Promise<void>;
105
109
  initClasses(): Promise<void>;
106
110
  isActiveOn(classInstance: object): boolean;
111
+ get frontendHostUri(): URL;
107
112
  get uri(): URL;
108
113
  get uriPort(): string | undefined;
109
114
  get uriProtocol(): string | undefined;
@@ -136,6 +141,7 @@ export declare class EndpointContext {
136
141
  * ipc/udp needs this
137
142
  */
138
143
  get contextName(): string;
144
+ get activeContext(): string | null;
139
145
  get appId(): string;
140
146
  get publicAssets(): {
141
147
  serverPath: string;
@@ -184,9 +184,14 @@ class EndpointContext {
184
184
  //#endregion
185
185
  //#endregion
186
186
  //#region constructor
187
+ /**
188
+ * Inside docker there is not need for https secure server
189
+ */
190
+ isRunningInsideDocker = false;
187
191
  constructor(originalConfig, configFn) {
188
192
  this.originalConfig = originalConfig;
189
193
  this.configFn = configFn;
194
+ this.isRunningInsideDocker = lib_8.UtilsOs.isRunningInDocker();
190
195
  }
191
196
  //#endregion
192
197
  //#region methods & getters / init
@@ -393,7 +398,14 @@ class EndpointContext {
393
398
  //#region @backend
394
399
  this.expressApp = express();
395
400
  this.initMiddlewares();
396
- this.serverTcpUdp = this.isHttpServer
401
+ const shouldStartHttpsSecureServer = this.isHttpServer && !this.isRunningInsideDocker;
402
+ this.logFramework &&
403
+ lib_10.Helpers.info(`
404
+
405
+ Starting server ${shouldStartHttpsSecureServer ? 'with' : 'without'} HTTPS secure server
406
+
407
+ `);
408
+ this.serverTcpUdp = shouldStartHttpsSecureServer
397
409
  ? new lib_7.https.Server({
398
410
  key: this.config.https?.key,
399
411
  cert: this.config.https?.cert,
@@ -447,12 +459,12 @@ class EndpointContext {
447
459
  console.log(`
448
460
 
449
461
 
450
- IS RUNNING IN DOCKER: ${lib_8.UtilsOs.isRunningInDocker()}
462
+ IS RUNNING IN DOCKER: ${this.isRunningInsideDocker}
451
463
 
452
464
  `);
453
465
  //#region @websqlFunc
454
466
  let databaseConfig = models_1.Models.DatabaseConfig.from({});
455
- if (lib_8.UtilsOs.isRunningInDocker()) {
467
+ if (this.isRunningInsideDocker) {
456
468
  if (this.USE_MARIADB_MYSQL_IN_DOCKER) {
457
469
  // Helpers.info('Running in docker, using in mysql database');
458
470
  // // TODO auto resolve database config in docker
@@ -583,7 +595,7 @@ class EndpointContext {
583
595
  }
584
596
  if (this.mode === 'backend-frontend(tcp+udp)') {
585
597
  return await new Promise(resolve => {
586
- if (lib_8.UtilsOs.isRunningInDocker()) {
598
+ if (this.isRunningInsideDocker) {
587
599
  // this.displayRoutes(this.expressApp);
588
600
  this.serverTcpUdp.listen(Number(this.uriPort), '0.0.0.0', () => {
589
601
  lib_10.Helpers.log(`Express server (inside docker) started 0.0.0.0:${this.uriPort}`);
@@ -1007,6 +1019,13 @@ class EndpointContext {
1007
1019
  }
1008
1020
  //#endregion
1009
1021
  //#region methods & getters / uri
1022
+ get frontendHostUri() {
1023
+ const url = this.config?.frontendHost?.startsWith('http')
1024
+ ? this.config.frontendHost
1025
+ : `${globalThis?.location?.protocol || 'http:'}//${this.config?.frontendHost}`;
1026
+ const uri = new url_1.URL(url.replace(/\/$/, ''));
1027
+ return uri;
1028
+ }
1010
1029
  get uri() {
1011
1030
  const url = this.host
1012
1031
  ? new url_1.URL(this.host)
@@ -1017,6 +1036,9 @@ class EndpointContext {
1017
1036
  }
1018
1037
  //#endregion
1019
1038
  get uriPort() {
1039
+ if (!this.uri?.origin?.includes('localhost')) {
1040
+ return this.config?.hostPortNumber?.toString();
1041
+ }
1020
1042
  return this.uri?.port;
1021
1043
  }
1022
1044
  get uriProtocol() {
@@ -1073,6 +1095,9 @@ class EndpointContext {
1073
1095
  return this.config.contextName;
1074
1096
  }
1075
1097
  //#endregion
1098
+ get activeContext() {
1099
+ return this.config.activeContext || null;
1100
+ }
1076
1101
  get appId() {
1077
1102
  return this.config.appId;
1078
1103
  }
@@ -1179,7 +1204,7 @@ class EndpointContext {
1179
1204
  }
1180
1205
  else {
1181
1206
  if (this.USE_MARIADB_MYSQL_IN_DOCKER) {
1182
- autoSave = !lib_8.UtilsOs.isRunningInDocker(); // in docker I am using mysql or posgress
1207
+ autoSave = !this.isRunningInsideDocker; // in docker I am using mysql or posgress
1183
1208
  }
1184
1209
  else {
1185
1210
  autoSave = true; // on docker with sqljs I need to save db
@@ -1320,8 +1345,13 @@ class EndpointContext {
1320
1345
  const methodConfig = classConfig.methods[methodName];
1321
1346
  // debugger
1322
1347
  const type = methodConfig.type;
1348
+ // this is quick fix - in docker global path should not be used
1349
+ const globalPathPart = this.isRunningInsideDocker ||
1350
+ !this.frontendHostUri?.origin?.includes('localhost') // fe with domain -> is in docker
1351
+ ? `${this.uriPathnameOrNothingIfRoot.replace(/\/$/, '')}/${constants_1.apiPrefix}/${this.contextName}`.replace(/\/\//, '/')
1352
+ : '';
1323
1353
  const expressPath = methodConfig.global
1324
- ? `/${methodConfig.path?.replace(/\//, '')}`
1354
+ ? `${globalPathPart}/${methodConfig.path?.replace(/\/$/, '')}`.replace(/\/\//, '/')
1325
1355
  : taon_helpers_1.TaonHelpers.getExpressPath(classConfig, methodConfig);
1326
1356
  // console.log({ expressPath });
1327
1357
  if (lib_10.Helpers.isNode || lib_10.Helpers.isWebSQL) {