ENV[“VARIABLE”].encoding return #<Encoding:ASCII-8BIT> on production when being assigned a unicode string

I’m using ENV[“VARIABLE”] inside my Rails app which being set to a unicode string.
On production (which is a docker container), this ENV[“VARIABLE”] is somehow encoded with Encoding:ASCII-8BIT (though ENV[“PWD”], for instance, is encoded with Encoding:UTF-8). On development, every variable is encoded with Encoding:UTF-8. The encoding of ASCII-8BIT prevent me to render the variable in a view. What is the cause? How could I fix?

  • Simple Docker image running Apache won't start up on Centos 7.2
  • Docker Daemon stop - Timeout for container defaults 10s
  • dokku - Run Rails 4 app from Subfolder
  • docker install nsenter , command not found
  • Docker-compose - Redis at 0.0.0.0 instead of 127.0.0.1
  • Best strategy for automatize a flow that need user interaction
  • Change .docker directory on Windows
  • can not connect to docker container mapping port
  • Sharing devices (webcam, USB drives, etc) with Docker
  • Installing specific version of node.js and npm in ubuntu image with Dockerfile
  • Cached Docker image?
  • How to get remote access to a private docker-registry?
  • Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.