mirror of
https://github.com/EvolutionAPI/evolution-api.git
synced 2025-12-19 11:52:20 -06:00
wip
This commit is contained in:
@@ -6,24 +6,24 @@ import * as https from 'https';
|
||||
import { configService, SslConf } from '../config/env.config';
|
||||
|
||||
export class ServerUP {
|
||||
static #app: Express;
|
||||
static #app: Express;
|
||||
|
||||
static set app(e: Express) {
|
||||
this.#app = e;
|
||||
}
|
||||
static set app(e: Express) {
|
||||
this.#app = e;
|
||||
}
|
||||
|
||||
static get https() {
|
||||
const { FULLCHAIN, PRIVKEY } = configService.get<SslConf>('SSL_CONF');
|
||||
return https.createServer(
|
||||
{
|
||||
cert: readFileSync(FULLCHAIN),
|
||||
key: readFileSync(PRIVKEY),
|
||||
},
|
||||
ServerUP.#app,
|
||||
);
|
||||
}
|
||||
static get https() {
|
||||
const { FULLCHAIN, PRIVKEY } = configService.get<SslConf>('SSL_CONF');
|
||||
return https.createServer(
|
||||
{
|
||||
cert: readFileSync(FULLCHAIN),
|
||||
key: readFileSync(PRIVKEY),
|
||||
},
|
||||
ServerUP.#app,
|
||||
);
|
||||
}
|
||||
|
||||
static get http() {
|
||||
return http.createServer(ServerUP.#app);
|
||||
}
|
||||
static get http() {
|
||||
return http.createServer(ServerUP.#app);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user