generator icon indicating copy to clipboard operation
generator copied to clipboard

[BUG] Demo from homepage does not work

Open cisarpavel opened this issue 1 year ago • 10 comments

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?

  • [X] I checked and didn't find similar issue

🏢 Have you read the Contributing Guidelines?

Are you willing to work on this issue ?

None

cisarpavel avatar Mar 27 '24 11:03 cisarpavel

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.

github-actions[bot] avatar Mar 27 '24 11:03 github-actions[bot]

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

derberg avatar Mar 27 '24 17:03 derberg

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

asyncio

cisarpavel avatar Mar 28 '24 05:03 cisarpavel

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?

lmgyuan avatar Apr 10 '24 00:04 lmgyuan

Sorry for late response. Root user worked. Thanks.

cisarpavel avatar Apr 10 '24 06:04 cisarpavel

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

lmgyuan avatar May 16 '24 01:05 lmgyuan

@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

derberg avatar May 16 '24 07:05 derberg

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

lmgyuan avatar Jul 24 '24 07:07 lmgyuan

@lmgyuan please go ahead

derberg avatar Aug 01 '24 14:08 derberg

@derberg I came across the same while installing the image using docker as of which I've opened a PR in website repo fixing this https://github.com/asyncapi/website/pull/3213

DhairyaMajmudar avatar Sep 11 '24 11:09 DhairyaMajmudar