Set something (a setting, variable, piece of configuration) to/at/for a specific value - programming and IT

The for option is incorrect in this context. In programming you set a value for the left-hand side, not the right-hand side. For instance, one could say "I set the configuration for the User class in user.json." In the offending statement, the most parsimonious phrasing is "x is set to {}", which is less wordy than the redundant "the value of x is set to {}". Set to is the English equivalent of JavaScript/Python/Java/C/C+* assignment operator =.