commit | 62f8b3752b4737bd81bb6bb86c0fb11bf6e195b3 | [log] [tgz] |
---|---|---|
author | Renovate bot <renovate-bot@avm99963.com> | Fri Dec 29 22:11:16 2023 +0000 |
committer | Adrià Vilanova MartÃnez <me@avm99963.com> | Sat Dec 30 00:41:02 2023 +0100 |
tree | d17ef7785b1829142508b2ebe4adf7e4d199f67b | |
parent | cd67239932224b16bf1426a137770094fccd9bc6 [diff] |
chore: Configure Renovate Change-Id: I08d594b0eb5bca581c5c534eee4e55665fe5893f
TWPT-server is the code for the TW Power Tools gRPC server and its frontend.
This repository is under active development, and is not ready yet for production.
To serve the frontend for development, follow these instructions:
docker-compose -f docker-compose.dev.yml up
to start the gRPC API, database and Envoy proxy (which will translate gRPC-Web <-> gRPC).docker exec -i twpt-server_db_1 mysql -u root twpt < schema/common.sql
and docker exec -i twpt-server_db_1 mysql -u root twpt < schema/kill-switch.sql
.docker exec -it twpt-server_db_1 mysql -u root twpt
and enter the following SQL sentence with your data to create the first authorized user: INSERT INTO KillSwitchAuthorizedUser (google_uid, email, access_level) VALUES ('', '{YOUR_EMAIL_ADDRESS}', 10);
.docker-compose -f docker-compose.dev.yml restart
.npm install
.make serve
.You can run the backend for development purposes by running go run .
in the //cmd/serve
folder. You may also build its docker image to allow it to interact with the frontend (since it needs Envy (the gRPC-Web proxy) to translate between gRPC and HTTP requests).
Use the docker-compose.yml
file instead of docker-compose.dev.yml
and follow steps 1-4 from the "frontend" section to spin up the backend.
For the frontend, run make deploy
in the //frontend
folder to deploy the frontend to Firebase.