Merge branch 'dev' of https://github.com/hay-kot/mealie into refactor/frontend

This commit is contained in:
hay-kot 2021-04-06 13:13:55 -08:00
commit 4905bc0153
6 changed files with 11 additions and 15 deletions

View file

@ -14,12 +14,9 @@ RUN curl -sSL https://raw.githubusercontent.com/python-poetry/poetry/master/get-
# Copy poetry.lock* in case it doesn't exist in the repo # Copy poetry.lock* in case it doesn't exist in the repo
COPY ./pyproject.toml /app/ COPY ./pyproject.toml /app/
# RUN poetry install
COPY ./mealie /app/mealie COPY ./mealie /app/mealie
RUN poetry install RUN poetry install
RUN ["poetry", "run", "python", "mealie/db/init_db.py"] RUN chmod +x /app/mealie/run.sh
RUN ["poetry", "run", "python", "mealie/services/image/minify.py"] CMD /app/mealie/run.sh reload
CMD ["poetry", "run", "python", "mealie/app.py"]

View file

@ -29,7 +29,7 @@ services:
db_type: sqlite db_type: sqlite
TZ: America/Anchorage # Specify Correct Timezone for Date/Time to line up correctly. TZ: America/Anchorage # Specify Correct Timezone for Date/Time to line up correctly.
volumes: volumes:
- ./app_data:/app_data - ./dev/data:/app/dev/data
- ./mealie:/app/mealie - ./mealie:/app/mealie
# Mkdocs # Mkdocs

View file

@ -22,13 +22,11 @@
<v-text-field <v-text-field
v-if="!options.isLoggingIn" v-if="!options.isLoggingIn"
v-model="user.name" v-model="user.name"
light="light"
prepend-icon="person" prepend-icon="person"
:label="$t('general.name')" :label="$t('general.name')"
></v-text-field> ></v-text-field>
<v-text-field <v-text-field
v-model="user.email" v-model="user.email"
light="light"
prepend-icon="mdi-email" prepend-icon="mdi-email"
validate-on-blur validate-on-blur
:label="$t('user.email')" :label="$t('user.email')"
@ -36,7 +34,6 @@
></v-text-field> ></v-text-field>
<v-text-field <v-text-field
v-model="user.password" v-model="user.password"
light="light"
class="mb-2s" class="mb-2s"
prepend-icon="mdi-lock" prepend-icon="mdi-lock"
:label="$t('user.password')" :label="$t('user.password')"
@ -47,7 +44,6 @@
<v-card-actions> <v-card-actions>
<v-btn <v-btn
v-if="options.isLoggingIn" v-if="options.isLoggingIn"
dark
color="primary" color="primary"
block="block" block="block"
type="submit" type="submit"

View file

@ -51,7 +51,7 @@ start_scheduler()
def main(): def main():
uvicorn.run( uvicorn.run(
"app:app", "app:app",
host="0.0.0.0", host="0.0.0.0",

View file

@ -47,11 +47,12 @@ def default_user_init(session: Session):
logger.info("Generating Default User") logger.info("Generating Default User")
db.users.create(session, default_user) db.users.create(session, default_user)
def main():
if __name__ == "__main__":
if sql_exists: if sql_exists:
print("Database Exists") print("Database Exists")
exit()
else: else:
print("Database Doesn't Exists, Initializing...") print("Database Doesn't Exists, Initializing...")
init_db() init_db()
if __name__ == "__main__":
main()

View file

@ -3,7 +3,7 @@
# Get Reload Arg `run.sh reload` for dev server # Get Reload Arg `run.sh reload` for dev server
ARG1=${1:-production} ARG1=${1:-production}
# Set Script Directory # Set Script Directory - Used for running the script from a different directory.
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )" DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
# # Initialize Database Prerun # # Initialize Database Prerun
@ -12,6 +12,8 @@ poetry run python $DIR/services/image/minify.py
# Migrations # Migrations
# TODO # TODO
# Migrations
# Set Port from ENV Variable
if [[ "$ARG1" = "reload" ]] if [[ "$ARG1" = "reload" ]]
then then