mirror of
https://github.com/danny-avila/LibreChat.git
synced 2025-12-24 04:10:15 +01:00
🐋 ci: Dockerfile.multi rewrite, maintain package integrity (#3772)
* chore: touch server * chore: dockerfile.multi first pass * refactor: remove prod-stage build, share dist files instead
This commit is contained in:
parent
d54458b3a6
commit
88d8706757
4 changed files with 30 additions and 33 deletions
|
|
@ -39,7 +39,7 @@ const startServer = async () => {
|
|||
|
||||
app.get('/health', (_req, res) => res.status(200).send('OK'));
|
||||
|
||||
// Middleware
|
||||
/* Middleware */
|
||||
app.use(noIndex);
|
||||
app.use(errorController);
|
||||
app.use(express.json({ limit: '3mb' }));
|
||||
|
|
@ -48,7 +48,7 @@ const startServer = async () => {
|
|||
app.use(staticCache(app.locals.paths.dist));
|
||||
app.use(staticCache(app.locals.paths.fonts));
|
||||
app.use(staticCache(app.locals.paths.assets));
|
||||
app.set('trust proxy', 1); // trust first proxy
|
||||
app.set('trust proxy', 1); /* trust first proxy */
|
||||
app.use(cors());
|
||||
|
||||
if (DISABLE_COMPRESSION !== 'true') {
|
||||
|
|
@ -61,12 +61,12 @@ const startServer = async () => {
|
|||
);
|
||||
}
|
||||
|
||||
// OAUTH
|
||||
/* OAUTH */
|
||||
app.use(passport.initialize());
|
||||
passport.use(await jwtLogin());
|
||||
passport.use(passportLogin());
|
||||
|
||||
// LDAP Auth
|
||||
/* LDAP Auth */
|
||||
if (process.env.LDAP_URL && process.env.LDAP_USER_SEARCH_BASE) {
|
||||
passport.use(ldapLogin);
|
||||
}
|
||||
|
|
@ -76,7 +76,7 @@ const startServer = async () => {
|
|||
}
|
||||
|
||||
app.use('/oauth', routes.oauth);
|
||||
// API Endpoints
|
||||
/* API Endpoints */
|
||||
app.use('/api/auth', routes.auth);
|
||||
app.use('/api/keys', routes.keys);
|
||||
app.use('/api/user', routes.user);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue