I have this under parameter section ,
Parameters: PlatformSelect: Description: Cockpit platform Select. Type: String Default: qa-1 AllowedValue
What about a combination of Fn::Join and Ref
Fn::Join
Ref
UserData: Fn::Base64: Fn::Join: - '' - - '#!/bin/bash\n' - 'print: echo' - !Ref 'PlatformSelect' - '>>test.txt\n'