Skip to content

Commit

Permalink
fix: when using old script args, just set the workers include var (im…
Browse files Browse the repository at this point in the history
…mich-app#9552)

* fix: when using old script args, just set the workers include var and move on

* fix: set process.title when using new bootstrap worker startup method
  • Loading branch information
zackpollard authored May 17, 2024
1 parent 85aca2b commit c8aa6a6
Showing 1 changed file with 11 additions and 8 deletions.
19 changes: 11 additions & 8 deletions server/src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,19 +32,22 @@ function bootstrap() {
return bootstrapImmichAdmin();
}
case 'immich': {
process.title = 'immich_server';
return bootstrapWorker('api');
if (!process.env.IMMICH_WORKERS_INCLUDE) {
process.env.IMMICH_WORKERS_INCLUDE = 'api';
}
break;
}
case 'microservices': {
process.title = 'immich_microservices';
return bootstrapWorker('microservices');
}
default: {
for (const worker of getWorkers()) {
bootstrapWorker(worker);
if (!process.env.IMMICH_WORKERS_INCLUDE) {
process.env.IMMICH_WORKERS_INCLUDE = 'microservices';
}
break;
}
}
process.title = 'immich';
for (const worker of getWorkers()) {
bootstrapWorker(worker);
}
}

void bootstrap();

0 comments on commit c8aa6a6

Please sign in to comment.