Skip to content

LinkStorms/linkstorm_datalayer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

65 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LinkStorm Data Layer

This service saves the data of URLs(user’s id, original version, shortened version, service provider, user’s note), users(id, username, email, hashed password, shortened URLs) and service tokens(user’s id, token). SQLAlchemy ORM was used in this service and SQLite as a database management system.

Managing the Environment and Dependencies

First install virtualenv with pip.

pip install virtualenv

Then create an empty virtual environment.

virtualenv .venv

Note that .venv is the name of the virtual environment directory, this directory is omitted in the .gitignore file.

After creating the virtual environment, activate it.

UNIX based Operating Systems (GNU/Linux, macOS, etc.)

source .venv/bin/activate

Windows

.\venv\Scripts\activate

Now you can install the required python packages in the clean environment you just created.

pip install -r requirements.txt

Running the Service

After installing the dependencies, you can go to the app directory and then run the service by executing the following command.

python main.py

If you want to change the port number, you can do so by changing the PORT constant in the settings.py file.

Further Questions?

Feel free to create an issue or contact us directly.

Releases

No releases published

Packages

No packages published

Languages