terraform/config: handle special resource attributes from resource templates