Hello ,
We upgraded from 5.2.1 to 5.4.13. For some reason it is no longer possible to update the value of a custom key variable if it contains a $-sign.
Steps to reproduce:
- Poweroff VM,
- select VM in GUI,
- select Conf,
- select Update Configuration button,
- select Context and Custom vars
- change the value of any key so it contains a $ sign.
The error eg: SOME_KEY and Some_Value_containing_a_$ :
[one.vm.updateconf] Error parsing: DISK_ID=1@^^@ETH0_CONTEXT_FORCE_IPV4=@^^@ETH0_DNS=x.x.x.x x.x.x.x.@^^@ETH0_GATEWAY=x.x.x.x@^^@ETH0_GATEWAY6=@^^@ETH0_IP=x.x.x.x@^^@ETH0_IP6=@^^@ETH0_IP6_PREFIX_LENGTH=@^^@ETH0_IP6_ULA=@^^@ETH0_MAC=02:00:d9:77:ed:7b@^^@ETH0_MASK=x.x.x.x@^^@ETH0_MTU=@^^@ETH0_NETWORK=x.x.x.x@^^@ETH0_SEARCH_DOMAIN=@^^@ETH0_VLAN_ID=@^^@ETH0_VROUTER_IP=@^^@ETH0_VROUTER_IP6=@^^@ETH0_VROUTER_MANAGEMENT=@^^@NETWORK=YES@^^@SET_HOSTNAME=rolftest@^^@SOME_KEY=Some_Vaulue_containing_a_$@^^@SSH_PUBLIC_KEY=$USER[SSH_PUBLIC_KEY]@^^@TARGET=hda. syntax error, unexpected EOA, expecting $end or VARIABLE or RSTRING at line 32591, columns 528:529
(ip-address redacted)
There is no problem filling the contextualisation with a $ at creation time, only afterwards. In 5.2.1 this was no issue. Not sure if this issue was introduced after 5.4.6.
The customer makes this change thru the XML-RPC API, but the problem is the same.
It seems the $ is also used for a template variable, like .e.g $VMID, is it a restricted char now ?
Any idea ?
Regards,
Rolf