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

Adding warning message when running APISIX in root path #1236

Merged
merged 1 commit into from
Mar 13, 2020

Conversation

sshniro
Copy link
Member

@sshniro sshniro commented Mar 12, 2020

Duplicate of #1201 and fix for #1196.

Based on the discussion on #1201, the PR only prints the warning message to the user and does not add the root configs to the nginx config

@moonming moonming merged commit 2a2762a into apache:master Mar 13, 2020
local script_path = arg[0]
if script_path:sub(1, 2) == './' then
apisix_home = trim(excute_cmd("pwd"))
if not apisix_home then
error("failed to fetch current path")
end

if string.match(apisix_home, '^/[root][^/]+') then
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we should use string.find.

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

Successfully merging this pull request may close these issues.

3 participants