Skip to content

Commit deefbb5

Browse files
Update environment variable from LAND_DNS_SERVER to Resolve for DNS configuration
Signed-off-by: Nikola Hristov <Nikola@PlayForm.Cloud>
1 parent 793c5d6 commit deefbb5

3 files changed

Lines changed: 5 additions & 5 deletions

File tree

Resource/dns-override.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
const dns = require("dns");
44
const { Resolver } = dns;
55

6-
const [host, portStr] = (process.env.LAND_DNS_SERVER || "127.0.0.1:5380").split(
6+
const [host, portStr] = (process.env.Resolve || "127.0.0.1:5380").split(
77
":",
88
);
99
const servers = [`${host}:${portStr}`];

Source/Source/SideCar/Spawn.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ const DNS_OVERRIDE:&str = include_str!("../../../Resource/dns-override.js");
1414
/// 2. Writes the DNS override JavaScript file to the app data directory
1515
/// 3. Configures the sidecar process with NODE_OPTIONS to require the DNS
1616
/// override script
17-
/// 4. Sets the LAND_DNS_SERVER environment variable with the local DNS server
17+
/// 4. Sets the Resolve environment variable with the local DNS server
1818
/// address
1919
/// 5. Spawns the sidecar process
2020
///
@@ -61,7 +61,7 @@ pub fn spawn_node_sidecar(app:&AppHandle, sidecar_name:&str) -> anyhow::Result<(
6161
app.shell()
6262
.sidecar(sidecar_name)?
6363
.env("NODE_OPTIONS", &node_opts)
64-
.env("LAND_DNS_SERVER", format!("127.0.0.1:{port}"))
64+
.env("Resolve", format!("127.0.0.1:{port}"))
6565
.spawn()?;
6666

6767
Ok(())

Source/Spawn.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ const DNS_OVERRIDE:&str = include_str!("../Resource/dns-override.js");
2222
/// 2. Writes the DNS override JavaScript file to the app data directory
2323
/// 3. Configures the sidecar process with NODE_OPTIONS to require the DNS
2424
/// override script
25-
/// 4. Sets the LAND_DNS_SERVER environment variable with the local DNS server
25+
/// 4. Sets the Resolve environment variable with the local DNS server
2626
/// address
2727
/// 5. Spawns the sidecar process
2828
///
@@ -69,7 +69,7 @@ pub fn spawn_node_sidecar(app:&AppHandle, sidecar_name:&str) -> anyhow::Result<(
6969
app.shell()
7070
.sidecar(sidecar_name)?
7171
.env("NODE_OPTIONS", &node_opts)
72-
.env("LAND_DNS_SERVER", format!("127.0.0.1:{port}"))
72+
.env("Resolve", format!("127.0.0.1:{port}"))
7373
.spawn()?;
7474

7575
Ok(())

0 commit comments

Comments
 (0)