_getInvokeConfig(func) {
    const codeAbsPath = this._resolveCodePath(this._cwd, func.codeUri);
    debug(`Resolved absolute path to code: ${codeAbsPath}.`);
    const timeout = this.isDebugging() ? MAX_DEBUG_TIMEOUT : func.timeout;
    return new FunctionConfig({
      timeout,
      codeAbsPath,
      region: this._profile.region,
      accountId: this._profile.accountId,
      identifier: func.identifier,
      handler: func.handler,
      runtime: func.runtime,
      memory: func.memorySize,
      envVars: func.envVars
    });
  }
Return a function config, which is constructed based on function metadata.

@param func the metadata of the function.
@returns {FunctionConfig} the function config.
@private