asyncapi / generator

Use your AsyncAPI definition to generate literally anything. Markdown documentation, Node.js code, HTML documentation, anything!
https://asyncapi.com/docs/tools/generator
Apache License 2.0
751 stars 208 forks source link

[BUG] Demo from homepage does not work #1153

Open cisarpavel opened 5 months ago

cisarpavel commented 5 months ago

Describe the bug.

Runnig demo usage using docker publish on project's homepage fails. docker run --rm -it -v ${PWD}/example:/app/example -v ${PWD}/output:/app/output \ asyncapi/cli generate fromTemplate https://bit.ly/asyncapi @asyncapi/html-template -o example

Expected behavior

Expected is that docs are generated using html template.

Screenshots

docker run --rm -it -v ${PWD}/example:/app/example -v ${PWD}/output:/app/output asyncapi/cli generate fromTemplate https://bit.ly/asyncapi @asyncapi/html-template -o example Generation in progress. Keep calm and wait a bit... done

Generator Error: Installation failed

How to Reproduce

docker run --rm -it -v ${PWD}/example:/app/example -v ${PWD}/output:/app/output asyncapi/cli generate fromTemplate https://bit.ly/asyncapi @asyncapi/html-template -o example

🥦 Browser

None

👀 Have you checked for similar open issues?

🏢 Have you read the Contributing Guidelines?

Are you willing to work on this issue ?

None

github-actions[bot] commented 5 months ago

Welcome to AsyncAPI. Thanks a lot for reporting your first issue. Please check out our contributors guide and the instructions about a basic recommended setup useful for opening a pull request.
Keep in mind there are also other channels you can use to interact with AsyncAPI community. For more details check out this issue.

derberg commented 5 months ago

can you specify which demo site you have in mind

the docker command should have --user=root included as some transpiration files need to be generated inside docker

cisarpavel commented 5 months ago

Sorry, I should be more precise. https://www.asyncapi.com/tools/generator

asyncio

lmgyuan commented 4 months ago
Screenshot 2024-04-09 at 8 31 35 PM

As I tried to replicate the issue, I actually ran into a different problem. It says that the generate is an unexpected identifier. May I ask if the doc needs to be updated? @derberg

Additionally, you mentioned that

the docker command should have --user=root included

Should we update the doc to reflect this?

cisarpavel commented 4 months ago

Sorry for late response. Root user worked. Thanks.

lmgyuan commented 3 months ago

@derberg This issue seems to be resolved already. Should we close it?

derberg commented 3 months ago

@lmgyuan would be good to update instruction in website. This is a common issue, a need to use root user - mainly because of necessary transpilation that happens in the template

lmgyuan commented 1 month ago

If no one else is going to raise a PR, I am happy to fix the instruction in website for this : )

derberg commented 3 weeks ago

@lmgyuan please go ahead