title: Using Django in AWS lambda
body: <p>I'm writing a simple http server in aws lambda and would like to use Django, however I'm not looking to deploy an entire django app on lambda through zappa.</p>
  
  <p>Is there any way to just import django's HttpResponse library in a lambda function like below?</p>
  
  <pre><code>from django.http import HttpResponse
  
  def lambda_handler(event, context):
      # TODO implement
  
      msg = "hello its me"
  
      return HttpResponse(msg, content_type='text/plain')
  </code></pre>
  
  <p>I've already created a deployment package with all the django libraries inside and uploaded to lambda, but I'm getting an error:</p>
  
  <pre><code>Requested setting DEFAULT_CHARSET, but settings are not configured. You must either define the environment variable DJANGO_SETTINGS_MODULE or call settings.configure() before accessing settings.: ImproperlyConfigured
  </code></pre>
  
  <p>any help is appreciated, thanks in advance!</p>