Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

I found 127.0.0.1 is not in slaves,dose it exist anathor way to choose lolalhost?? #22

Open
hyhy01 opened this issue Aug 28, 2018 · 0 comments

Comments

@hyhy01
Copy link

hyhy01 commented Aug 28, 2018

if main_host then
            local function sort_by_main_host(a, b)
                if a.host == main_host and b.host ~= main_host then
                    return true
                else
                    return false
                end
            end
            tbl_sort(slaves, sort_by_main_host)
        else
            -- Put any slaves on 127.0.0.1 at the front
            tbl_sort(slaves, sort_by_localhost)
        end

AND can choose master or slave to connect via command ?

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

No branches or pull requests

1 participant