这是indexloc提供的服务,不要输入任何密码
Skip to content

HTTPS support #11

@tmaslen

Description

@tmaslen

Hello again,

Have you thought about providing HTTPS support?

I got a crude version working by adding this code into Server.js...

const https = require('https');
const fs = require('fs');
const options = {
    cert: fs.readFileSync('/Users/tmo2367/Certs/localhost-cert.pem'),
    key: fs.readFileSync('/Users/tmo2367/Certs/localhost-key.pem'),
    passphrase: 'XXXXX'
};
https.createServer(options, this.app).listen(8443);

You'd want HTTPS to be enabled via a flag, and also the 3 option values too.

This is useful as I'm doing AWS Cognito integration, passing the user back to your serverless app requires a HTTPS URL to be added into Cognito.

Shall I make a PR if you're interested and not already started this?

Thanks,
/t

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions