feat: migrate configuration from custom format to YAML
- Replace custom directive-based config parser with YAML using gopkg.in/yaml.v3 - Rename config.example.conf to config.example.yml with YAML syntax - Update default config path to /etc/logcorrelator/logcorrelator.yml - Update Dockerfile.package to copy YAML config files - Update packaging scripts to install logcorrelator.yml - Update architecture.yml to document YAML configuration - Add yaml.v3 dependency to go.mod Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
This commit is contained in:
@ -37,10 +37,10 @@ case "$1" in
|
||||
chmod 750 /etc/logcorrelator
|
||||
|
||||
# Install default config if it doesn't exist
|
||||
if [ ! -f /etc/logcorrelator/logcorrelator.conf ]; then
|
||||
cp /usr/share/logcorrelator/logcorrelator.conf.example /etc/logcorrelator/logcorrelator.conf
|
||||
chown logcorrelator:logcorrelator /etc/logcorrelator/logcorrelator.conf
|
||||
chmod 640 /etc/logcorrelator/logcorrelator.conf
|
||||
if [ ! -f /etc/logcorrelator/logcorrelator.yml ]; then
|
||||
cp /usr/share/logcorrelator/logcorrelator.yml.example /etc/logcorrelator/logcorrelator.yml
|
||||
chown logcorrelator:logcorrelator /etc/logcorrelator/logcorrelator.yml
|
||||
chmod 640 /etc/logcorrelator/logcorrelator.yml
|
||||
fi
|
||||
|
||||
# Enable and start the service (if running in a real system, not container)
|
||||
|
||||
Reference in New Issue
Block a user