Skip to content

Conversation

@crpb
Copy link
Contributor

@crpb crpb commented Nov 13, 2025

  • remove useless requires+after to the same named socket. a .socket will automatically trigger a service if something want to talk to it. you will only ever need to enable the .socket and don't have to explicitly enable the .service in such a scenario. stichwort: triggering units
  • add after=mysql.service to not get any silly database errors anymore during boot because the database isn't accessible in the first try. the alias mysql.service was chosen to have a broader compatibility for anyone who isn't using mariadb.

triggering units?

@jengelh
Copy link
Member

jengelh commented Nov 14, 2025

After=mysql is mostly useless. It has no effect if the mysql db used by aapi runs on a remote host, and even for local processes, there is no guarantee that mysql.service is "quick enough" to create its socket before AAPI tries to use it.

 * remove useless requires+after to the same named socket.
   a .socket will automatically trigger a service if something want to
   talk to it. you will only ever need to enable the .socket and don't
   have to explicitly enable the .service in such a scenario.
   stichwort: triggering units
@crpb
Copy link
Contributor Author

crpb commented Nov 14, 2025

It has no effect if the mysql db used by aapi runs on a remote host,

right, didn't think of that ...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants