Skip to content

Sequelize logs all queries in production #99

@runleveldev

Description

@runleveldev

As an example, the server logs show this:

Oct 30 14:59:01 create-a-container node[146189]: Executing (default): SELECT `Service`.`id`, `Service`.`containerId`, `Service`.`type`, `Service`.`internalPort`, `Service`.`externalPort`, `Service`.`tls`, `Service`.`externalHostname`, `Service`.`createdAt`, `Service`.`updatedAt`, `Container`.`id` AS `Container.id`, `Container`.`hostname` AS `Container.hostname`, `Container`.`username` AS `Container.username`, `Container`.`osRelease` AS `Container.osRelease`, `Container`.`containerId` AS `Container.containerId`, `Container`.`macAddress` AS `Container.macAddress`, `Container`.`ipv4Address` AS `Container.ipv4Address`, `Container`.`aiContainer` AS `Container.aiContainer`, `Container`.`createdAt` AS `Container.createdAt`, `Container`.`updatedAt` AS `Container.updatedAt` FROM `Services` AS `Service` LEFT OUTER JOIN `Containers` AS `Container` ON `Service`.`containerId` = `Container`.`id` WHERE `Service`.`type` = 'http';

The expected behavior is for these logs in development, but when NODE_ENV=production these should be disabled.

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