Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

[feature request]enhanced server object capabilities for easier access and modification of nginx configuration #47

Open
mofantor opened this issue Apr 22, 2024 · 3 comments
Labels
enhancement New feature or request

Comments

@mofantor
Copy link
Contributor

propose to enhance the server object by adding new attributes and methods that will simplify the access and modification of its listening configuration, location details, and other pertinent settings. The following are potential enhancements and features that could be incorporated:

// get server by servername
server := conf.GetBlock(*.config.HTTP).GetServerByServerName("example.com")

// get all listening ports for the server
listenPorts := server.GetListenPorts()

// change the first listen port configuration to 8080
server.Listens[0].SetListenPort(8080)

// retrieve all location configurations for the server
locations := server.GetLocations()

Please consider implementing these functionalities to streamline working with complex server configurations and encourage more robust and dynamic management of Nginx setup through this library.

Let's discuss the feasibility and potential implementation details for these enhancements under this issue thread.

@tufanbarisyildirim tufanbarisyildirim added the enhancement New feature or request label Jun 8, 2024
@tufanbarisyildirim
Copy link
Owner

sounds good, would you like to take this?

@mofantor
Copy link
Contributor Author

I would like to develop these features. Some of the features have already been implemented in the project I am working on. After the completion of the subsequent work, I will submit a Pull Request.

@tufanbarisyildirim
Copy link
Owner

awesome! looking forward to it!

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants