You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@dubbo.apache.org by "yin1999 (via GitHub)" <gi...@apache.org> on 2024/05/22 08:14:35 UTC
[PR] fix(dubboctl): resolve the init logic of k8s environment [dubbo-kubernetes]
yin1999 opened a new pull request, #290:
URL: https://github.com/apache/dubbo-kubernetes/pull/290
## What is the purpose of the change
resolve the init logic of k8s environment, as the command given in [guide](https://dubbo-next.staged.apache.org/zh-cn/overview/mannual/java-sdk/quick-start/deploy/) cannot work correctly.
The config map of nacos is from [https://github.com/chickenlj/dubbo-admin/tree/refactor-with-go-integration/deploy](https://github.com/chickenlj/dubbo-admin/tree/0c5a543d5ab76b208508628bf48302e547a186fc/deploy).
## Brief changelog
resolve the init logic of k8s environment
## Verifying this change
Run the following command to init the k8s environment:
```bash
dubboctl manifest install --set profile=demo
# check the services
kubectl get services -n dubbo-system
```
## CheckList
- [x] Make sure there is a [GitHub_issue](https://github.com/apache/dubbo-kubernetes/issues) field for the change (usually before you start working on it). Trivial changes like typos do not require a GitHub issue. Your pull request should address just this issue, without pulling in other changes - one PR resolves one issue.
- [x] Each commit in the pull request should have a meaningful subject line and body.
- [x] Write a pull request description that is detailed enough to understand what the pull request does, how, and why.
- [x] GitHub Actions works fine on your own branch.
- [x] If this contribution is large, please follow the [Software Donation Guide](https://github.com/apache/dubbo/wiki/Software-donation-guide).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [PR] fix(dubboctl): resolve the init logic of k8s environment [dubbo-kubernetes]
Posted by "yin1999 (via GitHub)" <gi...@apache.org>.
yin1999 commented on code in PR #290:
URL: https://github.com/apache/dubbo-kubernetes/pull/290#discussion_r1609506251
##########
app/dubboctl/internal/manifest/render/render.go:
##########
@@ -325,8 +325,10 @@ func renderManifest(valsYaml string, cht *chart.Chart, builtIn bool, opts *Rende
if file == "" {
continue
}
+ // the formatted yaml file should terminate with a newline separator
if !strings.HasSuffix(file, YAMLSeparator) {
Review Comment:
Edge case:
```yaml
apiVersion: dubbo.apache.org/v1alpha1
kind: ConditionRoute
metadata:
name: admin-cp-conditionroute
namespace: dubbo-system
spec:
enabled: true
force: true
scope: service
runtime: true
priority: 100
key: org.apache.dubbo.samples.CommentService
configVersion: v3.0
conditions:
- method=getComment => region=Hangzhou
--- # there is no EOF (that is `\n` here)
```
The `if` condition will never be true, as the `util.SpaceFilter()` will not preserve the EOF line. Adding a new filter `ReserveEoFSpaceFilter` to resolve it.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [PR] fix(dubboctl): resolve the init logic of k8s environment [dubbo-kubernetes]
Posted by "chickenlj (via GitHub)" <gi...@apache.org>.
chickenlj merged PR #290:
URL: https://github.com/apache/dubbo-kubernetes/pull/290
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org