title: Is it possible to store a JSON file to an ENV variable with dotenv?
body: <p>I am using Google Drive API with my Rails application. The API is working fine. I have the following client_secret.json file:</p>
  
  <pre><code>{
    "type": "service_account",
    "project_id": "gobirdie-landing-page",
    "private_key_id": "xxxxx",
    "private_key": "-----BEGIN PRIVATE KEY----- xxxxx -----END PRIVATE KEY-----\n",
    "client_email": "xxxxxxx@gobirdie-landing-page.iam.gserviceaccount.com",
    "client_id": "xxxxxxxxx",
    "auth_uri": "xxxxxx",
    "token_uri": "xxxxxxx": "xxxxxxxx": "xxxxxxxxx"
  }
  </code></pre>
  
  <p>which is called in my controller</p>
  
  <pre><code>@session = GoogleDrive::Session.from_service_account_key("client_secret.json")
  
  </code></pre>
  
  <p>With this configuration no problem, I manage to use the API. However, I would like to store my JSON in the .env file like: </p>
  
  <pre><code>CLIENT_SECRET = "{
    "type": "service_account",
    "project_id": "gobirdie-landing-page",
    "private_key_id": "xxxxx",
    "private_key": "-----BEGIN PRIVATE KEY----- xxxxx -----END PRIVATE KEY-----\n",
    "client_email": "xxxxxxx@gobirdie-landing-page.iam.gserviceaccount.com",
    "client_id": "xxxxxxxxx",
    "auth_uri": "xxxxxx",
    "token_uri": "xxxxxxx": "xxxxxxxx": "xxxxxxxxx"
  }" 
  </code></pre>
  
  <p>And call it in the controller in this way </p>
  
  <pre><code>@session = GoogleDrive::Session.from_service_account_key(ENV['CLIENT_SECRET'])
  </code></pre>
  
  <p>Or in this way </p>
  
  <pre><code>@session = GoogleDrive::Session.from_service_account_key(JSON.parse(ENV['CLIENT_SECRET']))
  </code></pre>
  
  <p>But neither methods are working. So my question is : "Is it possible to store JSON file in an ENV variable ?"</p>