AppStream send custom logs to Cloudwatch using Cloudwatch agent

0

Hi

I am trying to send a custom application log from an AppStream fleet to Cloudwatch. I decided to give it a try like on a regular Windows EC2.

First thing: There is already a config file $Env:ProgramData\Amazon\AmazonCloudWatchAgent\amazon-cloudwatch-agent.json cofigure for AppStream itself. In a first run I tried editing this file and adding my own log file block. However strangely when I generate the AS Image and start a fleet, the config file no longer holds my edits (it seems to have reverted to the default config file)

I then tried leaving the default config file alone and just add a custom config file under $Env:ProgramData\Amazon\AmazonCloudWatchAgent\Configs directory. I know that at the end these will get consolidated in the toml file and it works well with EC2. In this case again it seems as if everything is reset when I generate the AS Image. I did find this blog post: https://aws.amazon.com/blogs/desktop-and-application-streaming/creating-custom-logging-and-amazon-cloudwatch-alerting-in-amazon-appstream-2-0/ but it look overly complicated for such simple thing I'm trying to achieve meaning pushing logs from a log file to cloudwatch

Any ideas how I can achieve this and why AS removes all customization I can make to the cloud watch config ?

profile picture
Amir
질문됨 일 년 전167회 조회
답변 없음

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠