-
Notifications
You must be signed in to change notification settings - Fork 32
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
Running with docker #46
Comments
Hey, this is on the roadmap but no ETA as unfortunately there are a lot of more pressing issues to be prioritized first. However, I'd probably start with off with something like: FROM node:20 # next LTS from end October
RUN apt-get update
RUN apt-get yarnpkg
# install mongo, at least for now
RUN apt-get install -yqqq mongodb-org
WORKDIR /usr/src/app
COPY package.json yarn.lock .
RUN yarn install
COPY . .
EXPOSE 3000
CMD [ "yarn", "dev" ] This is just a starting point though and I haven't tested this... if you come up with something good, please send as a PR! 🙏 😁 |
On a related note, is there somewhere with a list of the environment variables. I imagine it wouldn't be difficult to read them from the source code, but where would I look? |
Heh, no, I mean, here: $ $ grep -E 'getenv|environ.get' `find . -type f -name \*.py`
./api/utils/storage/S3Storage.py:AWS_S3_ENDPOINT_URL = os.environ.get("AWS_S3_ENDPOINT_URL", None)
./api/utils/storage/S3Storage.py:AWS_S3_DEFAULT_BUCKET = os.environ.get("AWS_S3_DEFAULT_BUCKET", None)
./api/getScheduler.py:HF_AUTH_TOKEN = os.getenv("HF_AUTH_TOKEN")
./api/getScheduler.py:DEFAULT_SCHEDULER = os.getenv("DEFAULT_SCHEDULER", SCHEDULERS[0])
./api/precision.py:MODEL_REVISION = os.getenv("MODEL_REVISION")
./api/send.py:SEND_URL = os.getenv("SEND_URL")
./api/send.py:SIGN_KEY = os.getenv("SIGN_KEY", "")
./api/send.py:container_id = os.getenv("CONTAINER_ID")
./api/download_checkpoint.py:CHECKPOINT_URL = os.environ.get("CHECKPOINT_URL", None)
./api/lib/vars.py:RUNTIME_DOWNLOADS = os.getenv("RUNTIME_DOWNLOADS") == "1"
./api/lib/vars.py:USE_DREAMBOOTH = os.getenv("USE_DREAMBOOTH") == "1"
./api/lib/vars.py:MODEL_ID = os.environ.get("MODEL_ID")
./api/lib/vars.py:PIPELINE = os.environ.get("PIPELINE")
./api/lib/vars.py:HF_AUTH_TOKEN = os.getenv("HF_AUTH_TOKEN")
./api/convert_to_diffusers.py:CHECKPOINT_CONFIG_URL = os.environ.get("CHECKPOINT_CONFIG_URL", None)
./api/convert_to_diffusers.py:CHECKPOINT_ARGS = os.environ.get("CHECKPOINT_ARGS", None)
./api/download.py:HF_AUTH_TOKEN = os.environ.get("HF_AUTH_TOKEN")
./api/download.py:RUNTIME_DOWNLOADS = os.environ.get("RUNTIME_DOWNLOADS")
./api/download.py: model_url=os.environ.get("MODEL_URL"),
./api/download.py: model_id=os.environ.get("MODEL_ID"),
./api/download.py: hf_model_id=os.environ.get("HF_MODEL_ID"),
./api/download.py: model_revision=os.environ.get("MODEL_REVISION"),
./api/download.py: model_precision=os.environ.get("MODEL_PRECISION"),
./api/download.py: checkpoint_url=os.environ.get("CHECKPOINT_URL"),
./api/download.py: checkpoint_config_url=os.environ.get("CHECKPOINT_CONFIG_URL"),
./api/loadModel.py:PIPELINE = os.getenv("PIPELINE")
./api/server.py:server.config.CORS_ORIGINS = os.getenv("CORS_ORIGINS") or "*" (with duplicates deleted) but you're right this should be more accessible. Maybe it will be a good idea to put them all in one file with comments. Note also the AWS code uses that |
That's great thanks. I don't see anything about mongo. I installed mongo, but it said something about a password, and I thought there would be more things I need to set. EDIT: tires screeching This is a node project, where did Python come from? Did you change to Python for your live site? |
Hey again.
I believe that's it... but let me know if you run into any thing else, and thanks for helping me consolidate these all in one place 😅 |
Does anyone have a recommended Dockerfile to run this with, or at least a good image to start with?
The text was updated successfully, but these errors were encountered: