thesharpowl / inno-alumni-portal Goto Github PK
View Code? Open in Web Editor NEWWebsite providing services for Innopolis University Alumni
License: MIT License
Website providing services for Innopolis University Alumni
License: MIT License
I followed the How to run
section from the README.md and could not enter the platform.
It seems that main sources of errors are:
.env
filedocker-compose-*.yml
filesI tried installation using Python.
Lines 38 to 47 in cfbd6ac
And got an error:
python3: can't open file '~/gh/inno-alumni-portal/main.py': [Errno 2] No such file or directory
Next, I tried installation using Docker.
Lines 49 to 56 in cfbd6ac
I got an error.
"docker build" requires exactly 1 argument.
See 'docker build --help'.
Usage: docker build [OPTIONS] PATH | URL | -
Build an image from a Dockerfile
I tried docker compose
.
docker compose -f docker-compose.yml up
I got an error.
Failed to load ~/Desktop/gh/inno-alumni-portal/.env: open ~/Desktop/gh/inno-alumni-portal/.env: no such file or directory
I created a .env
following the Settings
fields.
inno-alumni-portal/app/config.py
Lines 6 to 20 in cfbd6ac
# some random values
database_host="0.0.0.0"
database_port="5000"
database_password="abra"
database_name="foo"
database_username="bar"
# https://fastapi.tiangolo.com/advanced/security/oauth2-scopes/?h=secret_key#__tabbed_1_1
secret_key="09d25e094faa6ca2556c818166b7a9563b93f7099f6f0f4caa6cf63b88e8d3e7"
algorithm="HS256"
access_token_expire_minutes="30"
# https://github.com/sabuhish/fastapi-mail?tab=readme-ov-file#guide
mail_username="username"
mail_password="string"
mail_from="[email protected]"
mail_port="465"
mail_server="mail server"
mail_from_name="Alpha Beta"
Next, I ran docker compose
again
docker compose -f docker-compose.yml up
WARN[0000] Found orphan containers ([nginx certbot]) for this project. If you removed or renamed this service in your compose file, you can run this command with the --remove-orphans flag to clean it up.
[+] Running 2/0
✔ Container inno-alumni-backend Recreated 0.0s
✔ Container inno-alumni-frontend Recreated 0.0s
Attaching to inno-alumni-backend, inno-alumni-frontend
inno-alumni-backend | INFO: Will watch for changes in these directories: ['/usr/src/app']
inno-alumni-backend | INFO: Uvicorn running on http://0.0.0.0:8000 (Press CTRL+C to quit)
inno-alumni-backend | INFO: Started reloader process [1] using WatchFiles
inno-alumni-frontend |
inno-alumni-frontend | > [email protected] next-dev
inno-alumni-frontend | > next
inno-alumni-frontend |
inno-alumni-frontend |
inno-alumni-backend | INFO: Started server process [8]
inno-alumni-backend | INFO: Waiting for application startup.
inno-alumni-frontend | ready - started server on 0.0.0.0:3000, url: http://localhost:3000
inno-alumni-frontend | info - Loaded env from /usr/src/app/.env
inno-alumni-frontend | warn - The `app` directory is experimental. To enable, add `appDir: true` to your `next.config.js` configuration under `experimental`. See https://nextjs.org/docs/messages/experimental-app-dir-config
inno-alumni-frontend | warn - The `app` directory is experimental. To enable, add `appDir: true` to your `next.config.js` configuration under `experimental`. See https://nextjs.org/docs/messages/experimental-app-dir-config
inno-alumni-backend | {"is_panic":false,"message":"Server has closed the connection.","meta":null,"error_code":"P1017"}
inno-alumni-frontend | event - compiled client and server successfully in 1142 ms (1315 modules)
inno-alumni-backend | ERROR: Traceback (most recent call last):
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpcore/_exceptions.py", line 10, in map_exceptions
inno-alumni-backend | yield
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpcore/backends/sync.py", line 94, in connect_tcp
inno-alumni-backend | sock = socket.create_connection(
inno-alumni-backend | File "/usr/local/lib/python3.9/socket.py", line 844, in create_connection
inno-alumni-backend | raise err
inno-alumni-backend | File "/usr/local/lib/python3.9/socket.py", line 832, in create_connection
inno-alumni-backend | sock.connect(sa)
inno-alumni-backend | OSError: [Errno 99] Cannot assign requested address
inno-alumni-backend |
inno-alumni-backend | During handling of the above exception, another exception occurred:
inno-alumni-backend |
inno-alumni-backend | Traceback (most recent call last):
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpx/_transports/default.py", line 60, in map_httpcore_exceptions
inno-alumni-backend | yield
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpx/_transports/default.py", line 218, in handle_request
inno-alumni-backend | resp = self._pool.handle_request(req)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpcore/_sync/connection_pool.py", line 253, in handle_request
inno-alumni-backend | raise exc
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpcore/_sync/connection_pool.py", line 237, in handle_request
inno-alumni-backend | response = connection.handle_request(request)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpcore/_sync/connection.py", line 86, in handle_request
inno-alumni-backend | raise exc
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpcore/_sync/connection.py", line 63, in handle_request
inno-alumni-backend | stream = self._connect(request)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpcore/_sync/connection.py", line 111, in _connect
inno-alumni-backend | stream = self._network_backend.connect_tcp(**kwargs)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpcore/backends/sync.py", line 94, in connect_tcp
inno-alumni-backend | sock = socket.create_connection(
inno-alumni-backend | File "/usr/local/lib/python3.9/contextlib.py", line 137, in __exit__
inno-alumni-backend | self.gen.throw(typ, value, traceback)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpcore/_exceptions.py", line 14, in map_exceptions
inno-alumni-backend | raise to_exc(exc)
inno-alumni-backend | httpcore.ConnectError: [Errno 99] Cannot assign requested address
inno-alumni-backend |
inno-alumni-backend | The above exception was the direct cause of the following exception:
inno-alumni-backend |
inno-alumni-backend | Traceback (most recent call last):
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/prisma/engine/query.py", line 194, in spawn
inno-alumni-backend | data = self.request('GET', '/status')
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/prisma/engine/http.py", line 114, in request
inno-alumni-backend | resp = self.session.request(method, url, **kwargs)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/prisma/_sync_http.py", line 25, in request
inno-alumni-backend | return Response(self.session.request(method, url, **kwargs))
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpx/_client.py", line 821, in request
inno-alumni-backend | return self.send(request, auth=auth, follow_redirects=follow_redirects)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpx/_client.py", line 908, in send
inno-alumni-backend | response = self._send_handling_auth(
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpx/_client.py", line 936, in _send_handling_auth
inno-alumni-backend | response = self._send_handling_redirects(
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpx/_client.py", line 973, in _send_handling_redirects
inno-alumni-backend | response = self._send_single_request(request)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpx/_client.py", line 1009, in _send_single_request
inno-alumni-backend | response = transport.handle_request(request)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpx/_transports/default.py", line 218, in handle_request
inno-alumni-backend | resp = self._pool.handle_request(req)
inno-alumni-backend | File "/usr/local/lib/python3.9/contextlib.py", line 137, in __exit__
inno-alumni-backend | self.gen.throw(typ, value, traceback)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpx/_transports/default.py", line 77, in map_httpcore_exceptions
inno-alumni-backend | raise mapped_exc(message) from exc
inno-alumni-backend | httpx.ConnectError: [Errno 99] Cannot assign requested address
inno-alumni-backend |
inno-alumni-backend | The above exception was the direct cause of the following exception:
inno-alumni-backend |
inno-alumni-backend | Traceback (most recent call last):
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/starlette/routing.py", line 677, in lifespan
inno-alumni-backend | async with self.lifespan_context(app) as maybe_state:
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/starlette/routing.py", line 566, in __aenter__
inno-alumni-backend | await self._router.startup()
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/starlette/routing.py", line 656, in startup
inno-alumni-backend | handler()
inno-alumni-backend | File "/usr/src/app/app/main.py", line 34, in startup
inno-alumni-backend | db.connect()
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/prisma/client.py", line 263, in connect
inno-alumni-backend | self.__engine.connect(
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/prisma/engine/query.py", line 130, in connect
inno-alumni-backend | self.spawn(file, timeout=timeout, datasources=datasources)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/prisma/engine/query.py", line 213, in spawn
inno-alumni-backend | raise errors.EngineConnectionError(
inno-alumni-backend | prisma.engine.errors.EngineConnectionError: Could not connect to the query engine
inno-alumni-backend |
inno-alumni-backend | ERROR: Application startup failed. Exiting.
inno-alumni-backend |
inno-alumni-backend | db connected...
inno-alumni-frontend | info - Loaded env from /usr/src/app/.env
inno-alumni-frontend | wait - compiling...
inno-alumni-frontend | event - compiled client and server successfully in 351 ms (1315 modules)
inno-alumni-frontend | wait - compiling / (client and server)...
inno-alumni-frontend | event - compiled client and server successfully in 807 ms (2526 modules)
inno-alumni-frontend | wait - compiling /auth/login...
inno-alumni-frontend | event - compiled client and server successfully in 292 ms (2541 modules)
In the browser, I got a login page.
I clicked on Register
and got to the Register
page.
After filling the fields, I clicked Continue
and got to the Login
page.
I entered my new password.
I clicked Continue
and got an error in the lower right corner of the page.
I clicked on Innopolis University SSO
and was redirected to an /authorize
page. There was an error.
I returned to the Login
page.
I clicked on Admin login
.
I kept the default values in the fields and clicked Continue
. I got errors.
I changed the port mapping for the frontend
service in docker-compose-prod.yml
to 3000:80
.
I ran docker compose
on that file.
docker compose -f docker-compose-prod.yml up
I got these logs
[+] Running 3/0
✔ Container certbot Running 0.0s
✔ Container inno-alumni-backend Created 0.0s
✔ Container inno-alumni-frontend Recreated 0.0s
Attaching to certbot, inno-alumni-backend, inno-alumni-frontend, nginx
inno-alumni-frontend |
inno-alumni-frontend | > [email protected] start
inno-alumni-frontend | > next start -p 80
inno-alumni-frontend |
inno-alumni-frontend |
inno-alumni-backend | INFO: Started server process [1]
inno-alumni-backend | INFO: Waiting for application startup.
inno-alumni-frontend | ready - started server on 0.0.0.0:80, url: http://localhost:80
inno-alumni-backend | {"is_panic":false,"message":"Server has closed the connection.","meta":null,"error_code":"P1017"}
vnginx exited with code 1
inno-alumni-backend | ERROR: Traceback (most recent call last):
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpcore/_exceptions.py", line 10, in map_exceptions
inno-alumni-backend | yield
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpcore/backends/sync.py", line 94, in connect_tcp
inno-alumni-backend | sock = socket.create_connection(
inno-alumni-backend | File "/usr/local/lib/python3.9/socket.py", line 844, in create_connection
inno-alumni-backend | raise err
inno-alumni-backend | File "/usr/local/lib/python3.9/socket.py", line 832, in create_connection
inno-alumni-backend | sock.connect(sa)
inno-alumni-backend | OSError: [Errno 99] Cannot assign requested address
inno-alumni-backend |
inno-alumni-backend | During handling of the above exception, another exception occurred:
inno-alumni-backend |
inno-alumni-backend | Traceback (most recent call last):
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpx/_transports/default.py", line 60, in map_httpcore_exceptions
inno-alumni-backend | yield
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpx/_transports/default.py", line 218, in handle_request
inno-alumni-backend | resp = self._pool.handle_request(req)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpcore/_sync/connection_pool.py", line 253, in handle_request
inno-alumni-backend | raise exc
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpcore/_sync/connection_pool.py", line 237, in handle_request
inno-alumni-backend | response = connection.handle_request(request)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpcore/_sync/connection.py", line 86, in handle_request
inno-alumni-backend | raise exc
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpcore/_sync/connection.py", line 63, in handle_request
inno-alumni-backend | stream = self._connect(request)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpcore/_sync/connection.py", line 111, in _connect
inno-alumni-backend | stream = self._network_backend.connect_tcp(**kwargs)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpcore/backends/sync.py", line 94, in connect_tcp
inno-alumni-backend | sock = socket.create_connection(
inno-alumni-backend | File "/usr/local/lib/python3.9/contextlib.py", line 137, in __exit__
inno-alumni-backend | self.gen.throw(typ, value, traceback)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpcore/_exceptions.py", line 14, in map_exceptions
inno-alumni-backend | raise to_exc(exc)
inno-alumni-backend | httpcore.ConnectError: [Errno 99] Cannot assign requested address
inno-alumni-backend |
inno-alumni-backend | The above exception was the direct cause of the following exception:
inno-alumni-backend |
inno-alumni-backend | Traceback (most recent call last):
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/prisma/engine/query.py", line 194, in spawn
inno-alumni-backend | data = self.request('GET', '/status')
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/prisma/engine/http.py", line 114, in request
inno-alumni-backend | resp = self.session.request(method, url, **kwargs)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/prisma/_sync_http.py", line 25, in request
inno-alumni-backend | return Response(self.session.request(method, url, **kwargs))
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpx/_client.py", line 821, in request
inno-alumni-backend | return self.send(request, auth=auth, follow_redirects=follow_redirects)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpx/_client.py", line 908, in send
inno-alumni-backend | response = self._send_handling_auth(
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpx/_client.py", line 936, in _send_handling_auth
inno-alumni-backend | response = self._send_handling_redirects(
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpx/_client.py", line 973, in _send_handling_redirects
inno-alumni-backend | response = self._send_single_request(request)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpx/_client.py", line 1009, in _send_single_request
inno-alumni-backend | response = transport.handle_request(request)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpx/_transports/default.py", line 218, in handle_request
inno-alumni-backend | resp = self._pool.handle_request(req)
inno-alumni-backend | File "/usr/local/lib/python3.9/contextlib.py", line 137, in __exit__
inno-alumni-backend | self.gen.throw(typ, value, traceback)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/httpx/_transports/default.py", line 77, in map_httpcore_exceptions
inno-alumni-backend | raise mapped_exc(message) from exc
inno-alumni-backend | httpx.ConnectError: [Errno 99] Cannot assign requested address
inno-alumni-backend |
inno-alumni-backend | The above exception was the direct cause of the following exception:
inno-alumni-backend |
inno-alumni-backend | Traceback (most recent call last):
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/starlette/routing.py", line 677, in lifespan
inno-alumni-backend | async with self.lifespan_context(app) as maybe_state:
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/starlette/routing.py", line 566, in __aenter__
inno-alumni-backend | await self._router.startup()
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/starlette/routing.py", line 656, in startup
inno-alumni-backend | handler()
inno-alumni-backend | File "/usr/src/app/app/main.py", line 34, in startup
inno-alumni-backend | db.connect()
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/prisma/client.py", line 263, in connect
inno-alumni-backend | self.__engine.connect(
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/prisma/engine/query.py", line 130, in connect
inno-alumni-backend | self.spawn(file, timeout=timeout, datasources=datasources)
inno-alumni-backend | File "/usr/local/lib/python3.9/site-packages/prisma/engine/query.py", line 213, in spawn
inno-alumni-backend | raise errors.EngineConnectionError(
inno-alumni-backend | prisma.engine.errors.EngineConnectionError: Could not connect to the query engine
inno-alumni-backend |
inno-alumni-backend | ERROR: Application startup failed. Exiting.
inno-alumni-backend |
inno-alumni-backend | db connected...
inno-alumni-backend exited with code 3
nginx exited with code 1
I opened the page in a browser.
I could not proceed to the platform. The errors for different buttons were the same as for docker-compose-yml
.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.