I'm trying to start localstack in a containerized Jenkins build agent for unit testing. In other words, trying to start the localstack docker container from within a docker container. We do this all the time with other images, using the method of mounting `/var/run/docker.sock` in the "parent" container, but localstack will not start.

I get this error:

```
2019-11-08T18:53:53:ERROR:localstack.services.generic_proxy: Exception running proxy on port 8081: [Errno 13] Permission denied: '/tmp/localstack/server.test.pem' Traceback (most recent call last):
  File "/opt/code/localstack/localstack/services/generic_proxy.py", line 384, in run_cmd
    combined_file, cert_file_name, key_file_name = GenericProxy.create_ssl_cert(serial_number=self.port)
  File "/opt/code/localstack/localstack/services/generic_proxy.py", line 401, in create_ssl_cert
    return generate_ssl_cert(SERVER_CERT_PEM_FILE, serial_number=serial_number)
  File "/opt/code/localstack/localstack/utils/common.py", line 828, in generate_ssl_cert
    save_file(target_file, file_content)
  File "/opt/code/localstack/localstack/utils/common.py", line 642, in save_file
    with open(file, mode) as f:
PermissionError: [Errno 13] Permission denied: '/tmp/localstack/server.test.pem'
```

Port 8081 is not already in use, and `/tmp/localstack` is writable, so I don't understand why it's getting permission denied.
import os
import re
import sys
import json
import time
import signal
import traceback
import logging
import boto3
import subprocess
from requests.models import Response
from localstack import constants, config
from localstack.constants import (
    ENV_DEV, LOCALSTACK_VENV_FOLDER, ENV_INTERNAL_TEST_RUN, LOCALSTACK_INFRA_PROCESS,
    DEFAULT_PORT_APIGATEWAY_BACKEND, DEFAULT_PORT_SNS_BACKEND,
    DEFAULT_PORT_EC2_BACKEND, DEFAULT_SERVICE_PORTS)
from localstack.utils import common, persistence
from localstack.utils.common import (TMP_THREADS, run, get_free_tcp_port, is_linux,
    FuncThread, ShellCommandThread, get_service_protocol, in_docker, is_port_open)
from localstack.utils.server import multiserver
from localstack.utils.bootstrap import (
    setup_logging, is_debug, canonicalize_api_names, load_plugins, in_ci)
from localstack.utils.analytics import event_publisher
from localstack.services import generic_proxy, install
from localstack.services.es import es_api
from localstack.services.firehose import firehose_api
from localstack.services.awslambda import lambda_api
from localstack.services.generic_proxy import GenericProxy, GenericProxyHandler, ProxyListener
from localstack.services.dynamodbstreams import dynamodbstreams_api