Comments (10)
So, I'm kinda an idiot. Consul doesn't support lists, it's key/value. It supports lists in the manner that the value can be raw json or yaml. So if you want a list you have to store it as such. So just do:
test: |
- blah
- blah
- blah
If the code was modified, it would have to store it that way anyway .. May be kinda a pain if you already have existing yaml code, but we are starting from scratch so we're just gonna use this method.
from git2consul-go.
@Garagoth thanks opening this issue. Would you be willing to submit a pull request for this enhancement request?
from git2consul-go.
@Garagoth Have you encountered this error under other conditions?
We have a large config repo that does not have yaml lists as far as we know. We get the same error and have not yet been able to locate which file(s) could have an issue.
FWIW, we are trying to migrate from the breser/git2consul project and all of the files are yaml.
from git2consul-go.
@seanmalloy I am not fluent in go, so my pull request would be of poor quality I am afraid. I would need to learn a bit for this.
@stevenscg so far only with arrays of things that are not maps. Check for constructs like this as well:
key: [v1, v2, v3]
This is a valid array in yaml as well.
from git2consul-go.
@Garagoth Thanks. I'll try to look into it more later.
@seanmalloy Do you happen to know if there is a way to see which file is causing a problem when we see this error message? Maybe by increasing the log level?
from git2consul-go.
@Garagoth Thanks for that pattern! We found that we have 1 line like that in 1 file in each tree. I'll try removing it for now as a workaround.
from git2consul-go.
Any update on this? I'm seeing the same behaviour.
from git2consul-go.
@replicant0wnz unfortunately we're very short staffed and won't get to it any time soon. A pull request for this would be greatly appreciated. :)
from git2consul-go.
It sounds to me that there's an easy way to get this working, without code modifications. Should we close this PR or leave it open in the hopes somebody will tackle it someday?
from git2consul-go.
Well, it'll still crash if it receives a list. I'd say better sanity checking at a minimum. I may be able to tackle it later, but my golang knowledge is minimal.
from git2consul-go.
Related Issues (20)
- Add support to load KV from a file
- Current log format is missing a useful date HOT 3
- Consul Cluster Auto Discovery Feature
- Question: Are repositories synchronized sequentially? HOT 10
- Wrong default value for polling interval HOT 3
- Add support for Consul configuration through environmental variables
- Add support for configurable "repos:expand_keys" file extension HOT 2
- git2consul destroys kv store HOT 2
- Allow expanding of json values HOT 3
- Out of memory in some cases.
- Question: Connecting to Azure Devops git repos HOT 1
- Hidden files (e.g. .gitlab-ci.yml) cause failures
- Tx api size error
- Create Dockerfile to be able to use git2consul-go docker image
- slice interface case unable to load non map[interface{}]interface{}
- Running git2consul updates kv to one before most recent commit
- My branch name is topic/kurt.ding/fix_something,sync doesn't work
- I made some opinionated changes, may I can submit a PR ?
- Similarly named keys are inadvertently removed
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from git2consul-go.