title: Docker fails to provide creds for awslogs logging driver
body: <p>My docker-compose file:</p>
  <pre><code>version: &quot;2&quot;
  services:
    app:
      build:
        # Build an image from the Dockerfile in the current directory
        context: .
      ports:
        - 5000:5000
      environment:
        PORT: 5000
        NODE_ENV: production
  </code></pre>
  <p>And docker-compose.override</p>
  <pre><code>version: &quot;2&quot;
  networks:
      # This special network is configured so that the local metadata
      # service can bind to the specific IP address that ECS uses
      # in production
      credentials_network:
          driver: bridge
          ipam:
              config:
                  - subnet: &quot;169.254.170.0/24&quot;
                    gateway: 169.254.170.1
  services:
      # This container vends credentials to your containers
      ecs-local-endpoints:
          # The Amazon ECS Local Container Endpoints Docker Image
          image: amazon/amazon-ecs-local-container-endpoints
          volumes:
            # Mount /var/run so we can access docker.sock and talk to Docker
            - /var/run:/var/run
            # Mount the shared configuration directory, used by the AWS CLI and AWS SDKs
            # On Windows, this directory can be found at &quot;%UserProfile%\.aws&quot;
            - $HOME/.aws/:/home/.aws/
          environment:
            # define the home folder; credentials will be read from $HOME/.aws
            HOME: &quot;/home&quot;
            # You can change which AWS CLI Profile is used
            AWS_PROFILE: &quot;default&quot;
          networks:
              credentials_network:
                  # This special IP address is recognized by the AWS SDKs and AWS CLI 
                  ipv4_address: &quot;169.254.170.2&quot;
                  
      # Here we reference the application container that we are testing
      # You can test multiple containers at a time, simply duplicate this section
      # and customize it for each container, and give it a unique IP in 'credentials_network'.
      app:
          logging:
                driver: awslogs
                options:
                  awslogs-region: eu-west-3
                  awslogs-group: sharingmonsterlog
          depends_on:
              - ecs-local-endpoints
          networks:
              credentials_network:
                  ipv4_address: &quot;169.254.170.3&quot;
          environment:
            AWS_DEFAULT_REGION: &quot;eu-west-3&quot;
            AWS_CONTAINER_CREDENTIALS_RELATIVE_URI: &quot;/creds&quot;
  </code></pre>
  <p>I have added my AWS credentials to my mac using the aws configure command and the credentials are stored correctly in ~/.aws/credentials.</p>
  <p>I am using docker 2.2.0.4, docker-compose 1.25.4 and docker-machine 0.16.2.</p>
  <p>When I run docker-compose up I get the following error:</p>
  <blockquote>
  <p>ERROR: for scraper Cannot start service scraper: Failed to initialize logging driver: NoCredentialProviders: no valid providers in chain.</p>
  <p>Deprecated. For verbose messaging see aws.Config.CredentialsChainVerboseErrors</p>
  <p>ERROR: Encountered errors while bringing up the project.</p>
  </blockquote>
  <p>I believe this is because I need to set the AWS credentials in the Docker Daemon but I cannot work out how this is done on macOs High Sierra.</p>