diff --git a/.changeset/angry-dingos-stare.md b/.changeset/angry-dingos-stare.md new file mode 100644 index 000000000..1bb885c9a --- /dev/null +++ b/.changeset/angry-dingos-stare.md @@ -0,0 +1,8 @@ +--- +'renterd': minor +'@siafoundation/renterd-js': minor +'@siafoundation/renterd-react': minor +'@siafoundation/renterd-types': minor +--- + +Removed the allow redundant IPs setting. diff --git a/apps/renterd-e2e/src/fixtures/configResetSettings.ts b/apps/renterd-e2e/src/fixtures/configResetSettings.ts index 11f423c89..84d4c9f6e 100644 --- a/apps/renterd-e2e/src/fixtures/configResetSettings.ts +++ b/apps/renterd-e2e/src/fixtures/configResetSettings.ts @@ -30,7 +30,6 @@ export const configResetAllSettings = step( await setSwitchByLabel(page, 'prune', false) // hosts - await setSwitchByLabel(page, 'allowRedundantIPs', false) await fillTextInputByName(page, 'maxDowntimeHours', '330') await fillTextInputByName(page, 'maxConsecutiveScanFailures', '10') await fillTextInputByName(page, 'minProtocolVersion', '1.6.0') diff --git a/apps/renterd/contexts/config/fields.tsx b/apps/renterd/contexts/config/fields.tsx index 36328770d..a71054042 100644 --- a/apps/renterd/contexts/config/fields.tsx +++ b/apps/renterd/contexts/config/fields.tsx @@ -163,23 +163,6 @@ export function getFields({ }, // hosts - allowRedundantIPs: { - type: 'boolean', - category: 'hosts', - title: 'Redundant IPs', - description: ( - <> - Whether or not to allow forming contracts with multiple hosts in the - same IP subnet. The subnets used are /16 for IPv4, and /64 for IPv6. - - ), - suggestion: advancedDefaults?.allowRedundantIPs, - suggestionTip: `Defaults to ${ - advancedDefaults?.allowRedundantIPs ? 'on' : 'off' - }.`, - hidden: configViewMode === 'basic', - validation: {}, - }, maxDowntimeHours: { type: 'number', category: 'hosts', diff --git a/apps/renterd/contexts/config/transform.spec.ts b/apps/renterd/contexts/config/transform.spec.ts index d833e68da..2a2391aaf 100644 --- a/apps/renterd/contexts/config/transform.spec.ts +++ b/apps/renterd/contexts/config/transform.spec.ts @@ -50,7 +50,6 @@ describe('tansforms', () => { uploadTBMonth: new BigNumber('0.79'), storageTB: new BigNumber('1'), prune: true, - allowRedundantIPs: false, maxDowntimeHours: new BigNumber('1440'), maxConsecutiveScanFailures: new BigNumber('10'), minProtocolVersion: '', @@ -140,7 +139,6 @@ describe('tansforms', () => { uploadTBMonth: new BigNumber('0.785714285714285714285714285714'), storageTB: new BigNumber('1'), prune: true, - allowRedundantIPs: false, maxDowntimeHours: new BigNumber('1440'), maxConsecutiveScanFailures: new BigNumber('10'), minProtocolVersion: '', @@ -150,7 +148,6 @@ describe('tansforms', () => { ).toEqual({ enabled: true, hosts: { - allowRedundantIPs: false, maxDowntimeHours: 1440, maxConsecutiveScanFailures: 10, scoreOverrides: {}, @@ -181,7 +178,6 @@ describe('tansforms', () => { uploadTBMonth: new BigNumber('0.785714285714285714285714285714'), storageTB: new BigNumber('1'), prune: true, - allowRedundantIPs: false, maxDowntimeHours: new BigNumber('1440'), maxConsecutiveScanFailures: new BigNumber('10'), minProtocolVersion: '1.7.0', @@ -204,7 +200,6 @@ describe('tansforms', () => { enabled: false, hosts: { foobar: 'value', - allowRedundantIPs: false, maxDowntimeHours: 1440, maxConsecutiveScanFailures: 10, scoreOverrides: {}, @@ -236,7 +231,6 @@ describe('tansforms', () => { uploadTBMonth: new BigNumber('0.785714285714285714285714285714'), storageTB: new BigNumber('1'), prune: true, - allowRedundantIPs: false, maxDowntimeHours: new BigNumber('1440'), maxConsecutiveScanFailures: new BigNumber('10'), minProtocolVersion: '1.7.0', @@ -252,7 +246,6 @@ describe('tansforms', () => { ).toEqual({ enabled: true, hosts: { - allowRedundantIPs: false, maxDowntimeHours: 1440, maxConsecutiveScanFailures: 10, scoreOverrides: {}, @@ -285,7 +278,6 @@ describe('tansforms', () => { uploadTBMonth: new BigNumber('0.785714285714285714285714285714'), storageTB: new BigNumber('1'), prune: true, - allowRedundantIPs: false, maxDowntimeHours: new BigNumber('1440'), maxConsecutiveScanFailures: new BigNumber('10'), minProtocolVersion: '1.7.0', @@ -542,7 +534,6 @@ function buildAllResponses() { autopilot: { enabled: false, hosts: { - allowRedundantIPs: false, maxDowntimeHours: 1440, maxConsecutiveScanFailures: 10, scoreOverrides: {}, diff --git a/apps/renterd/contexts/config/transformDown.ts b/apps/renterd/contexts/config/transformDown.ts index ad12ef694..19fc1c8bd 100644 --- a/apps/renterd/contexts/config/transformDown.ts +++ b/apps/renterd/contexts/config/transformDown.ts @@ -71,7 +71,6 @@ export function transformDownAutopilot( storageTB, prune, // hosts - allowRedundantIPs: config.hosts.allowRedundantIPs, maxDowntimeHours: new BigNumber(config.hosts.maxDowntimeHours), maxConsecutiveScanFailures: new BigNumber( config.hosts.maxConsecutiveScanFailures diff --git a/apps/renterd/contexts/config/transformUp.ts b/apps/renterd/contexts/config/transformUp.ts index 11323de57..087d41e16 100644 --- a/apps/renterd/contexts/config/transformUp.ts +++ b/apps/renterd/contexts/config/transformUp.ts @@ -74,7 +74,6 @@ export function transformUpAutopilot( ...existingValues?.hosts, maxDowntimeHours: v.maxDowntimeHours.toNumber(), maxConsecutiveScanFailures: v.maxConsecutiveScanFailures.toNumber(), - allowRedundantIPs: v.allowRedundantIPs, scoreOverrides: existingValues?.hosts.scoreOverrides || {}, minProtocolVersion: v.minProtocolVersion, }, diff --git a/apps/renterd/contexts/config/types.ts b/apps/renterd/contexts/config/types.ts index 0aed43cde..e3ee2245c 100644 --- a/apps/renterd/contexts/config/types.ts +++ b/apps/renterd/contexts/config/types.ts @@ -26,7 +26,6 @@ export const inputValuesAutopilot = { storageTB: undefined as BigNumber | undefined, prune: false, // hosts - allowRedundantIPs: false, maxDowntimeHours: undefined as BigNumber | undefined, maxConsecutiveScanFailures: undefined as BigNumber | undefined, minProtocolVersion: '', @@ -135,7 +134,6 @@ export function getAdvancedDefaultsAutopilot( periodWeeks: new BigNumber(6), renewWindowWeeks: new BigNumber(2), amountHosts: new BigNumber(50), - allowRedundantIPs: false, maxDowntimeHours: new BigNumber(336), maxConsecutiveScanFailures: new BigNumber(10), minProtocolVersion: '1.6.0', @@ -145,7 +143,6 @@ export function getAdvancedDefaultsAutopilot( periodWeeks: new BigNumber(6), renewWindowWeeks: new BigNumber(2), amountHosts: new BigNumber(12), - allowRedundantIPs: false, maxDowntimeHours: new BigNumber(336), maxConsecutiveScanFailures: new BigNumber(10), minProtocolVersion: '1.6.0', diff --git a/apps/renterd/contexts/config/useAutopilotEvaluations.tsx b/apps/renterd/contexts/config/useAutopilotEvaluations.tsx index 83ebb6e3a..bf7b11eeb 100644 --- a/apps/renterd/contexts/config/useAutopilotEvaluations.tsx +++ b/apps/renterd/contexts/config/useAutopilotEvaluations.tsx @@ -455,7 +455,6 @@ export const valuesZeroDefaults: Values = { uploadTBMonth: new BigNumber(0), storageTB: new BigNumber(0), prune: false, - allowRedundantIPs: false, maxDowntimeHours: new BigNumber(0), maxConsecutiveScanFailures: new BigNumber(0), minProtocolVersion: '', diff --git a/libs/renterd-types/src/types.ts b/libs/renterd-types/src/types.ts index feeb4b159..1b6c32ee7 100644 --- a/libs/renterd-types/src/types.ts +++ b/libs/renterd-types/src/types.ts @@ -228,7 +228,6 @@ export type SiacoinElement = { } export type AutopilotHostsConfig = { - allowRedundantIPs: boolean scoreOverrides: { [key: PublicKey]: number } maxDowntimeHours: number maxConsecutiveScanFailures: number