-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
39c6cc6
commit b96d386
Showing
9 changed files
with
59 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
from masonite.environment import LoadEnvironment, env | ||
from masoniteorm.connections import ConnectionResolver | ||
|
||
# Loads in the environment variables when this page is imported. | ||
LoadEnvironment() | ||
|
||
""" | ||
The connections here don't determine the database but determine the "connection". | ||
They can be named whatever you want. | ||
""" | ||
DATABASES = { | ||
"default": env("DB_CONNECTION", "sqlite"), | ||
"sqlite": { | ||
"driver": "sqlite", | ||
"database": env("SQLITE_DB_DATABASE", "masonite.sqlite3"), | ||
"prefix": "", | ||
"log_queries": env("DB_LOG"), | ||
}, | ||
"mysql": { | ||
"host": "127.0.0.1", | ||
"driver": "mysql", | ||
"database": "masonite_permission", | ||
"user": "meyubaraj", | ||
"password": "MDB@123#go", | ||
"port": 3306, | ||
"prefix": "", | ||
"grammar": "mysql", | ||
"options": { | ||
"charset": "utf8mb4", | ||
}, | ||
"log_queries": env("DB_LOG"), | ||
}, | ||
"postgres": { | ||
"host": "127.0.0.1", | ||
"driver": "postgres", | ||
"database": "masonite_permission", | ||
"user": "meyubaraj", | ||
"password": "MDB@123#go", | ||
"port": 5432, | ||
"prefix": "", | ||
"grammar": "postgres", | ||
"log_queries": env("DB_LOG"), | ||
}, | ||
"mssql": { | ||
"driver": "mssql", | ||
"host": env("MSSQL_DATABASE_HOST"), | ||
"user": env("MSSQL_DATABASE_USER"), | ||
"password": env("MSSQL_DATABASE_PASSWORD"), | ||
"database": env("MSSQL_DATABASE_DATABASE"), | ||
"port": env("MSSQL_DATABASE_PORT"), | ||
"prefix": "", | ||
"log_queries": env("DB_LOG"), | ||
}, | ||
} | ||
|
||
DB = ConnectionResolver().set_connection_details(DATABASES) |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 0 additions & 12 deletions
12
src/masonite_permission/providers/PermissionGateProvider.py
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,2 @@ | ||
# flake8: noqa: E501 | ||
from .PermissionProvider import PermissionProvider | ||
from .PermissionGateProvider import PermissionGateProvider |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters