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

issue(docs): dartdoc documentation not completed #14

Closed
wzslr321 opened this issue Jul 13, 2021 · 2 comments · Fixed by #15
Closed

issue(docs): dartdoc documentation not completed #14

wzslr321 opened this issue Jul 13, 2021 · 2 comments · Fixed by #15

Comments

@wzslr321
Copy link
Owner

Documentation is still not completed - it requires to configure dartdoc - which unfortunately I am unable to test, because of my M1 Mac incompatibility with flutter image. It contains Dockerfile and commented out docker-compose config. I tried to make it work with my friend who helped me as tester, most of Dockerfile seems to work fine, but it can't properly find generated documentation and start server with dhttpd.

@akyunus
Copy link
Contributor

akyunus commented Jul 14, 2021

I try to make it work. u need dart and flutter sdk on docker client. also u need to install all dependencies of the app with pub get.
instaling all the sdk and other packages is it worth for it.

there are other options

1- push the generated docs to git repo. then u can serve the gerenated docs with a minimal webserver on docker. but It is not recommended to keep generateable content in git repo
a minimal server configuration will be simple like

FROM nginx:alpine
COPY doc/api/  /usr/share/nginx/html/

2 - generate the docs on host then u can serve the gerenated docs with a minimal webserver on docker so u will need a simple script to generate docs and docker compose up. but this is contrary to the docker intended use.

@wzslr321
Copy link
Owner Author

Approach described first is the one that already is in the configuration. Flutter SDK includes Dart SDK. In app's Dockerfile it runs flutter pub get and dartdoc properly finishes and logs documentation successfully generated in app/doc/api,
although dhttpd can't find it, also docker's volumes don't seem to create anything. It might be possible to fix using docker exec -itand look for the docs path inside the docker itself, so it would be possible to specify as dhttpd argument. But as you mentioned, installing all of this takes a while for a new contributor, so it may be not worth it on this stage, but consider situation when this project's front-end will finally grow and it'll be possible to dockerize flutter app itself and run it as web app. It will be inevitable then.

approach with nginx is not recommended, but it may be a good enough solution for now.

Last approach as you said, is contrary to the docker intended use, so I believe that shouldn't be used.

@akyunus akyunus mentioned this issue Jul 18, 2021
8 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants