Skip to content

Commit

Permalink
Added www and fixed ip logging
Browse files Browse the repository at this point in the history
  • Loading branch information
RobbinBaauw committed Feb 2, 2019
1 parent 84a4096 commit 0d4ab1c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion cshub-server/src/utilities/LoggingMiddleware.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@ import logger from "./Logger";
export const logMiddleware = (req: Request, userObj: IJWTToken = null) => {

const userData = userObj !== null ? `, uid: ${userObj.user.id}` : "";
logger.info(`[${req.ip}${userData}] - ${req.path}`);
logger.info(`[${req.headers["x-forwarded-for"] || req.connection.remoteAddress}${userData}] - ${req.path}`);
};
1 change: 1 addition & 0 deletions deployment/application/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ services:
- web
labels:
- traefik.frontend.rule=Host:${CLIENT_HOSTNAME}
- traefik.frontend.rule=Host:www.${CLIENT_HOSTNAME}
- traefik.frontend.port=${CLIENT_PORT_INTERNAL}
environment:
- VUE_APP_API_URL=${CLIENT_ENV_API_URL}
Expand Down

0 comments on commit 0d4ab1c

Please sign in to comment.