Fly.ioでProcfile的なことをする方法

自作サービスで、Railsとは別にDiscord Botを常時起動させておく必要があったが、Fly.ioにはProcfileなんてものは存在しなかった😢
いろいろ調べてみたところ、Fly.ioではfly.tomlなるものを使用すればいいということが分かったので備忘として。

The Fly platform uses fly.toml to configure applications for deployment. Configuration of builds, environment variables, internet-exposed services, disk mounts and release commands go here. TOML is a simple configuration file format. Here's a useful introduction on its syntax. You don't need to create a fly.toml file by hand. Running flyctl launch will create a fly.toml file for you. You can also generate one from an existing app by running flyctl config save. VSCode users: Install the Even Better TOML extension for automatic fly.toml validation and hints drawn from this documentation. App Configuration (fly.toml)

公式ドキュメントを確認したところ、どうやらfly.tomlはデプロイする際のアプリケーション設定を記述することができるらしい。
Questions / Helpも確認したところ、自分の探していることのスレッドを発見した。
どうやら、 [processes]セッションに記述すればよいみたい。

修正前のfly.toml

・・・省略・・・
[[services]]
  http_checks = []
  internal_port = 8080
  processes = ["app"]
  protocol = "tcp"
  script_checks = []

修正後のfly.toml

[[services]]
  http_checks = []
  internal_port = 8080
  processes = ["web"]
  protocol = "tcp"
  script_checks = []

[processes]
web = "bundle exec rails server -b [::] -p 8080"
bot = "rake discord_bot:start"

[processes]セクション内にRailsを起動するコマンド、rakeタスクを実行するコマンドを記述し、processes = ["app"]processes = ["web"]に置き換える。