Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upGitHub is where the world builds software
Millions of developers and companies build, ship, and maintain their software on GitHub — the largest and most advanced development platform in the world.
Add TLS support for file monitoring #88
Conversation
Issue: Below error encountered: ~ action is deprecated, consider using the 'stop' statement instead Resolved by changing ~ to stop.
|
@mostlyjason I am testing these changes on different scenarios. I am observing that a couple of changes are needed. Kindly put it on hold for another one day. Thanks. |
| @@ -2,7 +2,7 @@ | |||
|
|
|||
| #downloads configure-linux.sh | |||
| echo "INFO: Downloading dependencies - configure-linux.sh" | |||
| curl -s -o configure-linux.sh https://www.loggly.com/install/configure-linux.sh | |||
| curl -s -o configure-linux.sh https://raw.githubusercontent.com/Shwetajain148/install-script/tls-support-filemonitoring/Linux%20Script/configure-linux.sh | |||
Shwetajain148
Apr 17, 2017
Author
Contributor
@mchaudhary @mostlyjason For the time being, I have put the custom path here. After the changes will be deployed to the link URL, we can update it later.
@mchaudhary @mostlyjason For the time being, I have put the custom path here. After the changes will be deployed to the link URL, we can update it later.
|
@mchaudhary @mostlyjason I have tested the script and have made some changes. Now, it is working for me. Kindly review. Thanks |
| source configure-linux.sh "being-invoked" | ||
|
|
||
| ########## Variable Declarations - Start ########## | ||
| #name of the current script | ||
| SCRIPT_NAME=configure-file-monitoring.sh | ||
| #version of the current script | ||
| SCRIPT_VERSION=1.13 | ||
| SCRIPT_VERSION=1.14 |
| else | ||
| logMsgToConfigSysLog "WARN" "WARN: Your system logs are being send insecurely. We prefer to send system logs securely so switching to secure configuration." | ||
| else | ||
| logMsgToConfigSysLog "WARN" "WARN: Your system logs are being send insecurely. We prefer to send system logs securely so switching to secure configuration." |
mostlyjason
Aug 30, 2017
•
Contributor
sent...the secure
sent...the secure
Shwetajain148
Sep 1, 2017
Author
Contributor
@mchaudhary @mostlyjason, Since this change, was in configure-linux script so I made the above changes in existing PR for configure-linux script here: #102 so that these changes will not depend on this file-monitoring PR to be merged.
@mchaudhary @mostlyjason, Since this change, was in configure-linux script so I made the above changes in existing PR for configure-linux script here: #102 so that these changes will not depend on this file-monitoring PR to be merged.
| \$InputRunFileMonitor | ||
| #Add a tag for file events | ||
| template (name=\"$CONF_FILE_FORMAT_NAME\" type=\"string\" string=\"<%pri%>%protocol-version% %timestamp:::date-rfc3339% %HOSTNAME% %app-name% %procid% %msgid% [$LOGGLY_AUTH_TOKEN@41058 $TAG] %msg%\n\") |
mostlyjason
Aug 30, 2017
Contributor
How is $TAG set?
How is $TAG set?
Shwetajain148
Sep 1, 2017
Author
Contributor
@mostlyjason, From the very beginning, the default tag i.e. file is set into the LOGGLY_FILE_TAG variable if the user has not provided one externally using the parameter -tag in the command. Please refer the below code line-
Now, the user can pass multiple tags externally which get stored into the same LOGGLY_FILE_TAG variable separated by a comma and iterate inside the addTagsInConfiguration function and finally set into the $TAG variable. Please refer the below code line-
Once $TAG is set with either one or multiple tags, the same variable is used in the file-monitoring configuration. Please refer the below code line-
This is how $TAG set.
@mostlyjason, From the very beginning, the default tag i.e. file is set into the LOGGLY_FILE_TAG variable if the user has not provided one externally using the parameter -tag in the command. Please refer the below code line-
Now, the user can pass multiple tags externally which get stored into the same LOGGLY_FILE_TAG variable separated by a comma and iterate inside the addTagsInConfiguration function and finally set into the $TAG variable. Please refer the below code line-
Once $TAG is set with either one or multiple tags, the same variable is used in the file-monitoring configuration. Please refer the below code line-
This is how $TAG set.
mostlyjason
Sep 1, 2017
Contributor
Okay we should document how to set tags in https://www.loggly.com/docs/configure-syslog-script/. I don't see any descriptions for that parameter
Okay we should document how to set tags in https://www.loggly.com/docs/configure-syslog-script/. I don't see any descriptions for that parameter
Shwetajain148
Sep 4, 2017
Author
Contributor
@mostlyjason, I have added a Note to tell the users that how they can set the tag for all three file-monitoring, Nginx and Apache script on the document https://www.loggly.com/docs/configure-syslog-script/. I added this information after the Script Usage section, please review.
@mostlyjason, I have added a Note to tell the users that how they can set the tag for all three file-monitoring, Nginx and Apache script on the document https://www.loggly.com/docs/configure-syslog-script/. I added this information after the Script Usage section, please review.
I changed configure-linux.sh and configure-file-monitoring.sh scripts to add TLS support to both the scripts.
These are covering below points.