Project

General

Profile

Bug #11449

Allow variable as directive parameters in regexp validated inputs

Added by Vincent MEMBRÉ almost 3 years ago. Updated over 2 years ago.

Status:
Released
Priority:
N/A
Category:
Techniques
Target version:
Severity:
User visibility:
Effort required:
Priority:
0

Description

Host configuration technique only allow usage of values to be exact ip (regexp)

This regexp should allow variable to be used (ie sys.ipv4)


Related issues

Related to Rudder - User story #7006: Parameter validation in Rudder should accept rudder variables ( ${ } )ReleasedVincent MEMBRÉActions
#1

Updated by Vincent MEMBRÉ almost 3 years ago

File to modify is : ./techniques/systemSettings/networking/hostsConfiguration/2.0/metadata.xml

Variable is : HOSTS_IP

#2

Updated by Vincent MEMBRÉ almost 3 years ago

This problem should be resolved on a higher level, we don't want to fix every regexp field in every technique and maintain that.

We want to change how we check regex constraint by checking if the value contains a variable or not and accepting if this the case.

All possible case:

  • Only Value: 192.168.42.1
  • Only Variable: ${sys.ipv4}
  • Mix of Variable and Value: 192.168.${node.properties[subnet]}.1
#3

Updated by Vincent MEMBRÉ over 2 years ago

  • Status changed from New to In progress
  • Assignee set to Vincent MEMBRÉ
#4

Updated by Vincent MEMBRÉ over 2 years ago

  • Status changed from In progress to Pending technical review
  • Assignee changed from Vincent MEMBRÉ to François ARMAND
  • Pull Request set to https://github.com/Normation/rudder/pull/1757
#5

Updated by Nicolas CHARLES over 2 years ago

ticket name & commit name should probably be changed to "don't try to validate by regex entry that contains variables"

#6

Updated by Vincent MEMBRÉ over 2 years ago

  • Subject changed from Hosts technique does not allow to use $sys.ipv4 or any other variable to Allow variable as directive parameters in regexp validated inputs
#7

Updated by Vincent MEMBRÉ over 2 years ago

  • Status changed from Pending technical review to Pending release
#8

Updated by Vincent MEMBRÉ over 2 years ago

  • Status changed from Pending release to Released

This bug has been fixed in Rudder 4.1.8 and 4.2.1 which were released today.

#9

Updated by François ARMAND 3 months ago

  • Related to User story #7006: Parameter validation in Rudder should accept rudder variables ( ${ } ) added

Also available in: Atom PDF