Basico-PS / AutomationOrchestrator

Automation Orchestrator application to orchestrate and manage digital process automation (RPA)
BSD 3-Clause "New" or "Revised" License
36 stars 6 forks source link

Enhancement - Add hostname to allowed_hosts #63

Closed tikki100 closed 2 years ago

tikki100 commented 3 years ago

Currently, the settings.py file for Django contains the following allowed hosts:

https://github.com/Basico-PS/AutomationOrchestrator/blob/ab6943af76eab9002f313399ff0414246d4db257/automation_orchestrator/automation_orchestrator/settings.py#L70-L72

Where the last line only retrieves the IP of the current machine. I'd argue that adding the line socket.gethostname() by itself would be beneficial, as more often than not you access the webpage in a local environment by its name rather than its ip.

Using the other value in the array returned by socket.gethostbyname_ex() returns the hostname with the domain attached, and as such might be less useful than simply socket.gethostname()

mbalslow commented 2 years ago

Solved by https://github.com/Basico-PS/AutomationOrchestrator/commit/9688e300eedd357115c855aae67a975f06aabc89 and will be available in next release