Turkish Language variable values deployment problem

Hi to all,
I am using project variable template with multi tenant deployments. My appsettings.json files includes turkish characters like öçşığüÖÇŞİĞÜ…
Orıginal JSON like this:
“Subject”: “Teşekkürler”

Octopus Deploys like this:
“Subject”: “Te?ekk?rler”

How Can I fix this issue? With MSSQL Express DB or Is there any setting on Octopus? Thx.

Hi,
Thanks for reaching out, it looks like an encoding issue, however I tried to reproduce the issue on our end and could not get the same result. Are you deploying to Windows or Linux targets?
Are you able to query the Octopus DB directly to see if the variable values in the VariableSet table contains Turkish characters? I just want to see if we can narrow down where the encoding issue starts, if its from the DB or the deployment process. To check this you could run the following query where the OwnerId is the Id of the project in question.
SELECT [JSON] FROM [VariableSet] WHERE OwnerId='ProjectId (e.g. Projects-1)' and IsFrozen=0
If you look in the JSON field you should see the variables for your project.

Kind Regards,
Tom W

I am using Substitute Variables in Files and JSON Configuration Variables together in nuget deployment step. There is a “Output File Encoding” setting in Substitute Variables in Files but it is not working properly with utf8 and other things. Also (Detect from template) is not working.

Hi Tom, Sorry for latency, Target is Windows 2016 English tentacle. I am able to query, it is in Turkish in everywhere that is correct (Database, Octopus Project) except my target machine. This is a project variable template. Control type is multi-line textbox. Variable Values with turkish chars is in JSON format and over 4000 characters.

Hi,

Thanks for getting back to me, what version of Octopus and Tentacle are you running in your setup?

Kind Regards,
Tom

Server version v2018.7.0
Tentacle version 3.22.0

I have just upgraded to Server latest version v2018.7.14. There is no change.
I am sharing my octopus variable(#{My.Octopus.Variable}) in json file and variable value{…}.

{
  "ConnectionStrings": {
    "DbContext": "data source=SERVERNAME;initial catalog=DBNAME;persist security info=True;user id=USER;password=PASS;MultipleActiveResultSets=True;App=EntityFramework"
  },
  #{My.Octopus.Variable},
  "messageQueue": {
    "QueueName": "Planning.Consumer",
  }
}

#{My.Octopus.Variable} VALUE is:
{
“Port”: 587,
“EnableSsl”: true,
“SmtpAddress”: “smtp.gmail.com”,
“UserName”: "myuser@gmail.com",
“Password”: “mypass”,
“MailBody”: “helloğüşiöçĞÜŞİÖÇthere”,
“MailSubject”: “helloğüşiöçĞÜŞİÖÇthere”,
“From”: "myemail@gmail.com"
}
After deployment Output like this:
{
“ConnectionStrings”: {
“DbContext”: “data source=SERVERNAME;initial catalog=DBNAME;persist security info=True;user id=USER;password=PASS;MultipleActiveResultSets=True;App=EntityFramework”
},
{
Port": 587,
“EnableSsl”: true,
“SmtpAddress”: “smtp.gmail.com”,
“UserName”: "myuser@gmail.com",
“Password”: “mypass”,
“MailBody”: “hello???there”,
“MailSubject”: “hello???there”,
“From”: "myemail@gmail.com"
},
“messageQueue”: {
“QueueName”: “Planning.Consumer”,
}
}

Hi,
Thanks for sending that through, you mentioned you tried using the “Output File Encoding” option in the “Substitute Variables” section, in your message you mentioned utf8 however I just wanted to confirm the value you entered for that field, as it would need to be utf-8.
Are you able to ensure the value is in fact utf-8 and check the file encoding of the deployed file?
An easy way to do this would be to open the file in notepad++ and in the bottom right of the status bar it should show the current encoding of the file. Are you able to tell me what the encoding is on the source and deployed version of the file?

Kind Regards,
Tom

Hi Tom, When I want to open the json file, always it seems UTF-8. But I realised that problem on Octopus and fixed.

1-I am using Nuget deployment and activating Substitute Variables in Files defature. But leaving empty Output file encoding.(default)
2-I am defining Turkish character variable on Octopus.
3-Deploying release but turkish chars seems like ???
4-Changing Output file encoding to utf-8
5-When I want to recheck variable values on Octopus WebUI, Somehow Turkish characters replaced with ??? on Octopus Deploy tool like deployed config json.
6-I am changing the values to turkish chars again.
7-Deploying a new release
8-Problem fixed.

Thanks.

Hi,

I’m glad that you managed to get it working.
Please let me know if you have any further questions.

Kind Regards,
Tom

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.