Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Logging Create using Windows - Unable to pass format via command line #1363

Open
JamoCA opened this issue Dec 18, 2024 · 5 comments
Open

Logging Create using Windows - Unable to pass format via command line #1363

JamoCA opened this issue Dec 18, 2024 · 5 comments

Comments

@JamoCA
Copy link

JamoCA commented Dec 18, 2024

Could the "logger create" functions be updated to "accept a string or file path" for the "format" argument?

I'm using Fastly CLI v10.17.1 (0ce7568) and am having a very difficult time passing the "format" parameter when creating a sumologic log.

I noticed that the "VCL Create" function has a "content" argument that accepts either 1) a string or 2) a file path. The logging "format" argument would benefit by receiving the same treatment since it's impractical (and maybe impossible) to enter when using the Fastly CLI in a Windows environment.

The format payload that I'm using is the one that Sumo Logic recommends using with Fastly.
https://help.sumologic.com/docs/integrations/saas-cloud/fastly/
https://gist.github.com/JamoCA/e3d82dedad9c35a0c1bd3b444e367728

I also tried using the format posted on the Fastly documentation:
https://docs.fastly.com/en/guides/log-streaming-sumologic

No matter what I try and how I escape the string so, the CLI returns an error message.

If you desire more information, I have a Fastly support ticket #863460 open and the person helping me doesn't have an environment, has limited exposure to the CLI and may not be using Windows. I've provided them with complete information, but it seems very basic... except for the hoops required to format the "format" argument.

@JamoCA JamoCA added the bug Something isn't working label Dec 18, 2024
@kpfleming kpfleming added feature request and removed bug Something isn't working labels Dec 19, 2024
@kpfleming
Copy link
Contributor

Yes, this seems like a very reasonable request, since as you say the content being provided is subject to escaping and interpolation. We have the facility already in the CLI to do this. I can't commit to it being done soon, as we're about to be mostly shut down for the holidays/year-end, but we'll look into this in January.

@kpfleming
Copy link
Contributor

Please let the support person know that Jira ticket CDTOOL-989 (not visible to the public) has been created for this and should be linked to the support ticket.

@JamoCA
Copy link
Author

JamoCA commented Dec 19, 2024

We're new and currently migrating from Edgio. Our contract is up with them at the end of the month.

Does the v10.17.1 CLI work in a Windows environment for the "logging .. create" function? If so, what has to be done to the "format" payload in order for it to be posted successfully? (The CLI doesn't throw an error, but the Fastly API backend rejects it as "invalid".) Thanks.

@kpfleming
Copy link
Contributor

If I can suggest an alternative, it would be easier (and better for the community) to have this conversation on Fastly Connect. Conversations there are more easily discovered and more people can participate.

@JamoCA
Copy link
Author

JamoCA commented Dec 19, 2024

Thanks. I've cross-posted to "Fastly Connect" too.

Here's the forum link in case anyone seeing this issue wants to join the conversation there.
https://community.fastly.com/t/issues-with-windows-cli-logging-create-function/3749

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants