16159: Expires token after logout (WIP)
[arvados.git] / lib / boot / seed.go
index ce5d296bdd19a97042a8f43912e881c8172f460e..bd1e942658e9f50fba873d3de4f3a1c971dd54dc 100644 (file)
@@ -20,7 +20,14 @@ func (seedDatabase) Run(ctx context.Context, fail func(error), super *Supervisor
        if err != nil {
                return err
        }
-       err = super.RunProgram(ctx, "services/api", nil, []string{"ARVADOS_RAILS_LOG_TO_STDOUT=1"}, "bundle", "exec", "rake", "db:setup")
+       if super.ClusterType == "production" {
+               return nil
+       }
+       err = super.RunProgram(ctx, "services/api", runOptions{env: railsEnv}, "bundle", "exec", "rake", "db:setup")
+       if err != nil {
+               return err
+       }
+       err = super.RunProgram(ctx, "services/api", runOptions{env: railsEnv}, "bundle", "exec", "./script/get_anonymous_user_token.rb")
        if err != nil {
                return err
        }