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

Fixes ncurses problem and reduces image size. #164

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from

Conversation

emorozov
Copy link
Contributor

@emorozov emorozov commented Apr 26, 2023

Running FastAPI-template from docker fails because simple-term-menu requires tput utility from ncurses.

Also, changed Dockerfile to use two stages build, reducing the size by 4 times (150 Mb vs 595 Mb).

@s3rius
Copy link
Owner

s3rius commented Apr 26, 2023

Yeah. You're right. Now it's much better. I was thinking about removing docker images, but now it's much better, thanks.

@s3rius
Copy link
Owner

s3rius commented Apr 26, 2023

I ran into some issues, using this new image.

Commands to reproduce:

docker build . --tag=ftem
docker run -it ftem --name myproject --api-type rest --db mysql --orm tortoise --ci none --quite

At first it complains about unknown committer.

This can be solved by adding these lines into a final image:

RUN git config --global user.name "Fastapi Template"
RUN git config --global user.email "fastapi-template@no-reply.com"

But still, it cannot find gcc and mysql_admin. So we need to add them in the final image anyway. I guess that with posgress the problem with also occur, because some libraries depend on pg-dev.

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 this pull request may close these issues.

None yet

2 participants