xynginc 1.0.89 → 1.0.91

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
@@ -2,7 +2,7 @@
2
2
 
3
3
  This project uses code developed by NEHONIX (www.nehonix.com) under the NEHONIX Open Source License (NOSL) v1.0.
4
4
 
5
- XyPriss Nginx Controller - Simplifie la gestion de Nginx et SSL.
5
+ XyPriss Nginx Controller Simplifies Nginx and SSL management.
6
6
 
7
7
  [![xfpm version](https://badge.fury.io/js/%40xypriss%2Fxynginc.svg)](https://www.npmjs.com/package/xynginc)
8
8
  [![License: NOSL](https://img.shields.io/badge/License-NOSL-blue.svg)](https://dll.nehonix.com/licenses/NOSL)
@@ -2,13 +2,29 @@ import { ensureBinary } from "./mods/ensureBinary";
2
2
  import { Logger } from "./mods/logger";
3
3
  import { addDomain, applyConfig, checkRequirements, getStatus, installRequirementsHandler, listDomains, reloadNginx, removeDomain, testNginx, } from "./mods/requirements";
4
4
  const getSudo = (sudoPassword) => {
5
- // Attempt multiple ways to get the password, including XyPriss internal env if somehow exposed
6
- const envPwd = __sys__.__env__.get("SUDO_PASSWORD");
7
- // || (global as any).__sys__?.$env?.("SUDO_PASSWORD");
8
- const pwd = sudoPassword || envPwd;
5
+ let pwd = sudoPassword;
6
+ // Attempt multiple ways to get the password from the host project's environment
7
+ if (!pwd && typeof __sys__ !== "undefined" && __sys__.__env__) {
8
+ const projectRoot = globalThis.__sys__?._primaryRoot ||
9
+ globalThis.__sys__?._internalRoot ||
10
+ process.cwd();
11
+ if (typeof __sys__.__env__.getForRoot === "function") {
12
+ pwd = __sys__.__env__.getForRoot("SUDO_PASSWORD", projectRoot);
13
+ }
14
+ if (!pwd) {
15
+ pwd = __sys__.__env__.get("SUDO_PASSWORD");
16
+ }
17
+ }
18
+ // Strip wrapping quotes if present in .env (e.g., SUDO_PASSWORD="Test")
19
+ if (pwd) {
20
+ if ((pwd.startsWith('"') && pwd.endsWith('"')) ||
21
+ (pwd.startsWith("'") && pwd.endsWith("'"))) {
22
+ pwd = pwd.slice(1, -1);
23
+ }
24
+ }
9
25
  if (pwd) {
10
26
  if (sudoPassword) {
11
- Logger.info(`[XyNginC] Using sudo password provided via plugin options(${sudoPassword.slice(0, 2)}***).`);
27
+ Logger.info(`[XyNginC] Using sudo password provided via plugin options(${pwd.slice(0, 2)}***).`);
12
28
  }
13
29
  else {
14
30
  Logger.info("[XyNginC] Using sudo password injected from environment variables.");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "xynginc",
3
- "version": "1.0.89",
3
+ "version": "1.0.91",
4
4
  "description": "XyPriss Nginx Controller - Automatic Nginx & SSL management for XyPriss servers",
5
5
  "author": "Seth Eleazar - iDevo",
6
6
  "license": "NOSL",
@@ -1,9 +1,9 @@
1
1
  {
2
2
  "$internal": {
3
- // $(pkg).name dynamically reads the "name" field from your package.json.
3
+ // &(pkg).name dynamically reads the "name" field from your package.json.
4
4
  // This avoids duplicating the plugin name and keeps the config in sync.
5
- "$(pkg).name": {
6
- "type": "plugin",
7
- },
8
- },
5
+ "&(pkg).name": {
6
+ "type": "plugin"
7
+ }
8
+ }
9
9
  }
@@ -1,11 +1,11 @@
1
1
  --- XYPRISS SIGNATURE (G3) ---
2
- Manifest: xynginc@1.0.89
2
+ Manifest: xynginc@1.0.91
3
3
  Min-Engine: 1.0.81
4
- Fingerprint: sha256:10ba2d6f1d40958d98791dad84f3d0a31031b4e02c80268f0c35d80c71d77d40
5
- Identity: ed25519:a58b17a3e46302dd3ae5538bc9b8b991c57f4c5fe2e7d8ac41803de818d947f4
4
+ Fingerprint: sha256:528683a10d34bbd3202d63026467c67783d03a68242cdca43cd0c3e775a07dd1
5
+ Identity: ed25519:0e2e1accdbba45480979305256d50d368ae6cc2c0d7ee378c5f1999ae834cf58
6
6
  Privileges: XHS.HOOK.LIFECYCLE.REGISTER,XHS.HOOK.LIFECYCLE.SERVER_START,XHS.HOOK.LIFECYCLE.SERVER_STOP,XHS.HOOK.LIFECYCLE.SERVER_READY
7
- Expires: 2027-04-28T20:31:00Z
7
+ Expires: 2027-09-12T13:45:56Z
8
8
  Revision: sha256:none
9
9
  --- BEGIN CRYPTOGRAPHIC PROOF ---
10
- base64:Ssaaen09HIVlrhoB8xdHw78aP8i/qPVEEjSyma6Q8SyeeNu+Lg1R55shLhDmMYZUoQ2wwcMCCHNCAo4jIi+vBw==
10
+ base64:4IQrfdTzQgE0onhmKPoT54zzAJ2oj34hrWiIiZXapzl+SNdSOBW/6LVtqf3B5Rbba8n3Q61mSXm+vTgIuPTXCA==
11
11
  --- END XYPRISS SIGNATURE ---
package/bin/xynginc DELETED
Binary file