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

fix: allow config.yaml to be updated when already present for standalone mode #494

Merged
merged 9 commits into from
Sep 11, 2023

Conversation

Revolyssup
Copy link
Contributor

@Revolyssup Revolyssup commented Sep 6, 2023

Fixed #495
In this PR https://github.com/apache/apisix-docker/pull/491/files, the logic was changed so that if config.yaml is already present then it is not updated or initialised.
But the update is necessary for standalone mode where config_provider is changed to config.yaml.

This change makes sure that if the file doesn't exist then it is initialised. Otherwise relevant fields are updated for standalone mode

NOTE: yq utility is being downloaded at runtime so the startup time for standalone mode might increase by few seconds.

@Revolyssup Revolyssup requested review from soulbird, shreemaan-abhishek and monkeyDluffy6017 and removed request for soulbird September 6, 2023 09:49
Copy link
Contributor

@shreemaan-abhishek shreemaan-abhishek left a comment

Choose a reason for hiding this comment

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

Signed-off-by: Ashish Tiwari <[email protected]>
Signed-off-by: Ashish Tiwari <[email protected]>
Signed-off-by: Ashish Tiwari <[email protected]>
Signed-off-by: Ashish Tiwari <[email protected]>
Copy link
Member

@kayx23 kayx23 left a comment

Choose a reason for hiding this comment

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

Thanks for adding the test and example!

example/docker-compose-standalone.yml Outdated Show resolved Hide resolved
@apache apache deleted a comment from shreemaan-abhishek Sep 8, 2023
debian/Dockerfile Outdated Show resolved Hide resolved
debian/Dockerfile Outdated Show resolved Hide resolved
@kayx23 kayx23 dismissed shreemaan-abhishek’s stale review September 11, 2023 04:06

proposed change already done

@kayx23 kayx23 merged commit 328fc9d into apache:master Sep 11, 2023
AlinsRan pushed a commit that referenced this pull request Sep 11, 2023
@kamly
Copy link
Contributor

kamly commented Sep 25, 2023

hi, why delete

if [ ! -f "${PREFIX}/conf/apisix.yaml" ]; then
fi

I think this judgment is needed, If delete it, there will be an error message.

image

#482

@kamly kamly mentioned this pull request Sep 25, 2023
@Revolyssup
Copy link
Contributor Author

@kamly This if condition check wasn't removed in the PR

@kamly
Copy link
Contributor

kamly commented Sep 25, 2023

@Revolyssup
Copy link
Contributor Author

Revolyssup commented Sep 25, 2023

@kamly You're right. But this still didn't cause the issue. The issue was because it takes time for few things to be setup in container now. Though this is still an issue because it removed apisix.yaml. I will readd it.

@kamly
Copy link
Contributor

kamly commented Sep 25, 2023

i fix it #502

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.

bug: v3.5.0 standalone mode, connection refused while connecting to http://127.0.0.1:2379/v3/kv/range
6 participants