[go: nahoru, domu]

Skip to content

Commit

Permalink
api, docker: add env variable to set loglevel
Browse files Browse the repository at this point in the history
  • Loading branch information
gessecarneiro authored and otavio committed Sep 19, 2022
1 parent 50575dc commit 592e837
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 0 deletions.
5 changes: 5 additions & 0 deletions api/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,15 @@ import (
"context"

"github.com/kelseyhightower/envconfig"
"github.com/shellhub-io/shellhub/pkg/loglevel"
"github.com/sirupsen/logrus"
"github.com/spf13/cobra"
)

func init() {
loglevel.SetLogLevel()
}

func main() {
rootCmd := &cobra.Command{Use: "api"}

Expand Down
1 change: 1 addition & 0 deletions docker-compose.dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ services:
- SHELLHUB_ENTERPRISE=${SHELLHUB_ENTERPRISE}
- SHELLHUB_CLOUD=${SHELLHUB_CLOUD}
- SHELLHUB_ENV=${SHELLHUB_ENV}
- SHELLHUB_LOG_LEVEL=${SHELLHUB_LOG_LEVEL}
ui:
image: ui
build:
Expand Down
1 change: 1 addition & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ services:
- TELEMETRY=${SHELLHUB_TELEMETRY}
- TELEMETRY_SCHEDULE=${SHELLHUB_TELEMETRY_SCHEDULE}
- SESSION_RECORD_CLEANUP_SCHEDULE=${SHELLHUB_SESSION_RECORD_CLEANUP_SCHEDULE}
- SHELLHUB_LOG_LEVEL=${SHELLHUB_LOG_LEVEL}
depends_on:
- mongo
links:
Expand Down

0 comments on commit 592e837

Please sign in to comment.