<!-- Love localstack? Please consider supporting our collective:
👉  https://opencollective.com/localstack/donate -->

# Type of request: This is a ...

- [x] bug report
- [ ] feature request

# Detailed description
I get a 404 when I request a file I uploaded via a HEAD request.
This only happens when using the new edge router port.
I think there's faulty logic in the edge router when looking at HEAD requests.

## Expected behavior

I expect the behavior I get from requesting via the dedicated S3 port (HTTP 200 if a file exists)

## Actual behavior

A 404 on HEAD request through the edge router port.

# Steps to reproduce
```
version: '2.2'

services:
  localstack:
    image: localstack/localstack
    ports:
      - '4566:4566'
    environment:
      - SERVICES=s3
      - HOSTNAME_EXTERNAL=s3.test

```
```
docker-compose up -d
```
Making a bucket and uploading a file:
```
AWS_ENDPOINT_URL=http://s3.test:4566
aws --endpoint-url=$AWS_ENDPOINT_URL s3 mb s3://attachments
aws --endpoint-url=$AWS_ENDPOINT_URL s3 cp test s3://attachments
```
Lastly, HEADing the file to see if it exists.
```
$ curl -I $AWS_ENDPOINT_URL/attachments/test -H 'Authorization: aaa'
HTTP/1.1 404 Not Found
Server: BaseHTTP/0.6 Python/3.8.2
Date: Wed, 03 Jun 2020 21:28:46 GMT
Content-Length: 21
Access-Control-Allow-Origin: *
Access-Control-Allow-Methods: HEAD,GET,PUT,POST,DELETE,OPTIONS,PATCH
Access-Control-Allow-Headers: authorization,content-type,content-md5,cache-control,x-amz-content-sha256,x-amz-date,x-amz-security-token,x-amz-user-agent,x-amz-target,x-amz-acl,x-amz-version-id,x-localstack-target,x-amz-tagging
Access-Control-Expose-Headers: x-amz-version-id
```
Localstack logs from requesting via *:4566
```
localstack_1  | Starting edge router (https port 4566)...
localstack_1  | Starting mock S3 service in http ports 4566 (recommended) and 4572 (deprecated)...
localstack_1  | 2020-06-03T21:04:36:INFO:localstack.multiserver: Starting multi API server process on port 38679
localstack_1  | Ready.
localstack_1  | 2020-06-03T21:04:41:INFO:localstack.utils.persistence: Restored 10 API calls from persistent file: /tmp/localstack/recorded_api_calls.json
localstack_1  | 2020-06-03T21:05:09:INFO:localstack.services.edge: Unable to find forwarding rule for host "s3.test:4566", path "/attachments/test", target header "", auth header ""
```

Switching the exposed port to 4572 and requesting through there gives me:
```
AWS_ENDPOINT_URL=http://s3.test:4572
```
```
$ curl -I $AWS_ENDPOINT_URL/attachments/test -H 'Authorization: aaa'
HTTP/1.1 200 OK
Server: BaseHTTP/0.6 Python/3.8.2
Date: Wed, 03 Jun 2020 21:39:38 GMT
Content-Type: binary/octet-stream
ETag: "d41d8cd98f00b204e9800998ecf8427e"
last-modified: Wed, 03 Jun 2020 21:31:11 GMT
Content-Length: 0
Access-Control-Allow-Origin: *
x-amz-request-id: 3144F10D603C9424
x-amz-id-2: MzRISOwyjmnup3144F10D603C94247/JypPGXLh0OVFGcJaaO3KW/hRAqKOpIEEp
Access-Control-Allow-Methods: HEAD,GET,PUT,POST,DELETE,OPTIONS,PATCH
Access-Control-Allow-Headers: authorization,content-type,content-md5,cache-control,x-amz-content-sha256,x-amz-date,x-amz-security-token,x-amz-user-agent,x-amz-target,x-amz-acl,x-amz-version-id,x-localstack-target,x-amz-tagging
Access-Control-Expose-Headers: x-amz-version-id
```
else event_publisher.EVENT_S3_DELETE_BUCKET)
            event_publisher.fire_event(event_type, payload={'n': event_publisher.get_hash(bucket_name)})
        
        if method == 'PUT' and parsed.query == 'policy':
            response._content = ''
            response.status_code = 204
            return response
        
        if method == 'GET' and response.status_code == 404 and parsed.query != 'website':
            s3_client = aws_stack.connect_to_service('s3')
            try:
                
                s3_client.head_bucket(Bucket=bucket_name)
                website_config = s3_client.get_bucket_website(Bucket=bucket_name)
                error_doc_key = website_config.get('ErrorDocument', {}).get('Key')
                if error_doc_key:
                    error_object = s3_client.get_object(Bucket=bucket_name, Key=error_doc_key)
                    response.status_code = 200
                    response._content = error_object['Body'].read()
                    response.headers['content-length'] = len(response._content)
            except ClientError:
                
                pass
        if response is not None:
            reset_content_length = False
            
            append_cors_headers(bucket_name, request_method=method, request_headers=headers, response=response)
            append_last_modified_headers(response=response)
            append_list_objects_marker(method, path, data, response)
            fix_location_constraint(response)