title: Is it possible to add paths to the PATH environment variable through serverless.yml?
body: <p>When I create an AWS Lambda Layer, all the contents / modules of my zip file go to <code>/opt/</code> when the AWS Lambda executes. This easily becomes cumbersome and frustrating because I have to use absolute imports on all my lambdas. Example:</p>
  
  <pre><code>import json
  import os
  import importlib.util
  spec = importlib.util.spec_from_file_location("dynamodb_layer.customer", "/opt/dynamodb_layer/customer.py")
  module = importlib.util.module_from_spec(spec)
  spec.loader.exec_module(module)
  
  def fetch(event, context):
  
      CustomerManager = module.CustomerManager
      customer_manager = CustomerManager()
  
      body = customer_manager.list_customers(event["queryStringParameters"]["acquirer"])
  
      response = {
          "statusCode": 200,
          "headers": {
              "Access-Control-Allow-Origin": "*"
          },
          "body": json.dumps(body)
      }
  
      return response
  </code></pre>
  
  <p>So I was wondering, is it possible to add these /opt/paths to the PATH environment variable by beforehand through serverless.yml? In that way, I could just <code>from dynamodb_layer.customer import CustomerManager</code>, instead of that freakish ugliness.</p>