Skip to content

Commit

Permalink
url
Browse files Browse the repository at this point in the history
  • Loading branch information
Erutis committed Aug 28, 2024
1 parent e87e6f7 commit 959748a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion alembic.ini
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ version_path_separator = os # Use os.pathsep. Default configuration used for ne
# are written from script.py.mako
# output_encoding = utf-8

sqlalchemy.url = postgresql://nyc:gis@localhost:5432/nyc
sqlalchemy.url = None


[post_write_hooks]
Expand Down
4 changes: 3 additions & 1 deletion migrations/env.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@

from app.tables import FeedItem, Trajectory, metadata

import os

# this is the Alembic Config object, which provides
# access to the values within the .ini file in use.
config = context.config
Expand Down Expand Up @@ -40,7 +42,7 @@ def run_migrations_offline() -> None:
script output.
"""
url = config.get_main_option("sqlalchemy.url")
url = os.getenv("DATABASE_URL")
context.configure(
url=url,
target_metadata=target_metadata,
Expand Down

0 comments on commit 959748a

Please sign in to comment.