Skip to content

Commit

Permalink
fix(db): get db endpoint by env
Browse files Browse the repository at this point in the history
  • Loading branch information
huangzhiran authored Nov 14, 2023
2 parents 2da2dea + e767725 commit 6f394b1
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion cmd/node/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ func main() {
h := slog.NewTextHandler(os.Stderr, &slog.HandlerOptions{Level: programLevel})
slog.SetDefault(slog.New(h))

dbMigrate()
viper.MustBindEnv("ENDPOINT")
viper.MustBindEnv("RISC0_SERVER_ENDPOINT")
viper.MustBindEnv("HALO2_SERVER_ENDPOINT")
Expand All @@ -30,6 +29,8 @@ func main() {
viper.MustBindEnv("OPERATOR_PRIVATE_KEY")
viper.MustBindEnv("DATABASE_URL")

dbMigrate()

vmHandler := vm.NewHandler(
map[vm.Type]string{
vm.Risc0: viper.Get("RISC0_SERVER_ENDPOINT").(string),
Expand Down

0 comments on commit 6f394b1

Please sign in to comment.