Where is the luigi config file?
Asked Answered
A

2

8

I have installed luigi by pip command and I would like to change the port for the web UI. I tried to find the config file but I couldn't. Do I need to create one?

Ahrendt answered 19/5, 2017 at 8:51 Comment(0)
O
10

You can start luigid with the --port option.

luigid --port 80

Configuration file locations are:

  • /etc/luigi/luigi.cfg
  • luigi.cfg (or its legacy name client.cfg) in your current working directory
  • LUIGI_CONFIG_PATH environment variable

in increasing order of preference. You do need to create one. e.g.,

[core]
default-scheduler-host=www.example.com
default-scheduler-port=8088
Objective answered 19/5, 2017 at 14:2 Comment(1)
On Windows, the first configuration filepath is not global, but relative to the drive letter. For instance, if your current directory is W:\abc\xyz, then the 1st config file location is W:\etc\luigi\luigi.cfg.Rib
M
2

In spite of the documentation saying otherwise, the port configuration from the config file is not used, at least in some versions or some circumstances

Until this is resolved, you should always use the --port option of luigid:

luigid --port 12345

Also see https://github.com/spotify/luigi/issues/2235

For other configuration options a config file should be used. See https://luigi.readthedocs.io/en/stable/configuration.html

For a configuration global to the host you can create a file:

/etc/luigi/luigi.cfg

Make sure it is readable by the user that runs luigid and luig.

Alternatively a local configuration file that will be recognized is

luigi.cfg

which you would have to create in the current working directory.

If you want a custom config file location you could set the environment variable LUIGI_CONFIG_PATH to the full path of your config file.

Money answered 16/11, 2018 at 4:54 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.