I have a Yesod app which I am deploying to Heroku in a Docker container. The app uses Amazon SES to send emails. When running the app locally using yesod devel this works fine, but in the container on Heroku I get the following error:
HttpExceptionRequest Request {
host = "email.eu-west-1.amazonaws.com"
port = 443
secure = True
requestHeaders = [("Content-Type","application/x-www-form-
urlencoded"),("Date","Wed, 20 Sep 2017 12:39:49 +0000"),("X-Amzn-
Authorization","AWS3-HTTPS AWSAccessKeyId=AKIAIBUN4ZEOKYKOB35A,
Algorithm=HmacSHA256,
Signature=xh3fi4EJOAe0LOZVCng5NRZIw2D+6P++0aO4Q5Dy0gw=")]
path = "/"
queryString = ""
method = "POST"
proxy = Nothing
rawBody = False
redirectCount = 10
responseTimeout = ResponseTimeoutDefault
requestVersion = HTTP/1.1
}
(ConnectionFailure Network.BSD.getProtocolByName: does not exist (no
such protocol name: tcp))
I'm thinking I might need to install some extra packages in the container. Here's the Dockerfile:
FROM ubuntu:17.04
RUN apt-get update && apt-get install -y libpq-dev
WORKDIR /app
ADD . /app
EXPOSE 8080
ENV PGHOST localhost
CMD "./run"