Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
526 commits
Select commit Hold shift + click to select a range
5f06d3a
Merge branch 'frontend-react' of github.com:0mdb/collide into fronten…
0mdb Jan 24, 2023
857d508
get search options using react-query
0mdb Jan 24, 2023
f2c3aa7
Enjoy some newwwww colours
phaedrat Jan 27, 2023
fd1e8e7
uncomment memgraph objects
0mdb Jan 27, 2023
4653b6d
remove temp Home component
0mdb Jan 27, 2023
2b82afc
Merge branch 'frontend-react' of github.com:0mdb/collide into fronten…
0mdb Jan 27, 2023
d32a28e
fix 3d graph background color
0mdb Jan 27, 2023
7f502c4
disable refetch on focus
0mdb Jan 27, 2023
f27529e
removing unused arg
Jan 28, 2023
f55aff9
remove settings from sidebar until there are more settings
0mdb Jan 29, 2023
92ca930
add tailwind settings page for future
0mdb Jan 29, 2023
2ea2515
remove login/signup and direct button to home
0mdb Jan 29, 2023
492057e
add stats container to landing
0mdb Jan 29, 2023
74d4e38
remove login from nav for now
0mdb Jan 29, 2023
fd4ac50
add tailwind forms for future settings page
0mdb Jan 29, 2023
6c83866
ensure backend and memgraph is up before frontend starts
0mdb Jan 29, 2023
fdd31a8
remove memgraph objects troubleshooting startup..
0mdb Jan 29, 2023
41a5da9
show loading while graph is fetching #15
0mdb Jan 29, 2023
0b5a4aa
better loading spinner, still wip
0mdb Jan 29, 2023
2ce950c
Merge branch 'frontend-react' of https://github.com/0mdb/collide into…
Jan 30, 2023
f4f92ee
Add home2 for mobile layout testing
0mdb Feb 1, 2023
ffb9b76
Centralize API calls
0mdb Feb 4, 2023
ef708e8
separate components
0mdb Feb 4, 2023
a44cdc0
convert tailwind icons to blueprintjs
0mdb Feb 4, 2023
960695c
formatting
0mdb Feb 4, 2023
856ba28
idt
0mdb Feb 4, 2023
f819e07
Better ratio for resizing graph
0mdb Feb 4, 2023
1fba353
Add some relevant stats WIP
0mdb Feb 7, 2023
d02d7fb
changing start scripts to use pypy3
Feb 10, 2023
23d4836
increasing aggregation threshold step to avoid so many loops during a…
Feb 10, 2023
1020b7e
changing psycopg2 for psycopg2cffi, pulling out the async db stuff (d…
Feb 10, 2023
258f859
I had to add values for a lot of these fields (I think the compiler r…
Feb 10, 2023
9c626f5
rework of graph build
Feb 10, 2023
5c270e6
docker and compose files for pypy conversion
Feb 10, 2023
69def9b
pyscopg2cffi compat registration; other changes to make it work
Feb 10, 2023
e4511f1
changed to pypy; I don't remember why the initial data script is comm…
Feb 10, 2023
937006a
Add tag line to stats
0mdb Feb 12, 2023
b9b83a5
prevent overflow
0mdb Feb 12, 2023
2164c3f
add get graph function to select graph 2D or 3D
0mdb Feb 12, 2023
188226b
dont refetchOnWindowFocus
0mdb Feb 12, 2023
2a00d0d
center spinner and make bigger
0mdb Feb 12, 2023
9987bf4
center search bar. Ok now on mobile. Fix dropdown backgroundColor
0mdb Feb 12, 2023
f30e2c6
adjust max size of graph
0mdb Feb 12, 2023
99c7a57
on node click search for that node. #8
0mdb Feb 13, 2023
fc9eeb7
adjust flex direction
0mdb Feb 13, 2023
a90d3ed
add LobbyRadar branding
0mdb Feb 16, 2023
f695196
first stab at hero sections for LobbyRadar
0mdb Feb 16, 2023
4ce2c3b
add detailed hero section
0mdb Feb 16, 2023
6dbe311
collide to LobbyRadar
0mdb Feb 16, 2023
1b43328
collide.io to LobbyRadar
0mdb Feb 16, 2023
d459543
graphType selector... probably needs to be a context not hook
0mdb Feb 16, 2023
43816ac
move graphselector button off graph
0mdb Feb 16, 2023
10091cb
add graphtype selector to sidebar WIP
0mdb Feb 16, 2023
adb101f
add dark mode switch in tailwindui
0mdb Feb 17, 2023
bfdf793
rename search results function for clarity
0mdb Feb 17, 2023
b3404a1
simplify force graph function
0mdb Feb 17, 2023
3dba4e5
enable search for home2
0mdb Feb 17, 2023
3ae1174
add hook to track current selection
0mdb Feb 17, 2023
1c3f7e1
breakout search component to own file
0mdb Feb 17, 2023
27e24f3
add empty graph placeholder component
0mdb Feb 18, 2023
c50c879
remove example graph default and replace with empty graph
0mdb Feb 18, 2023
97d09c3
coool transitions on moble and colors
0mdb Feb 18, 2023
33e50e5
useless graph tweaks
0mdb Feb 18, 2023
4b8ab81
smaller checkmark on selected item in dropdown
0mdb Feb 18, 2023
1a0316b
use props instead of hooks to manage search state
0mdb Feb 18, 2023
06f7653
minor formatting
0mdb Feb 18, 2023
412c953
change default to home2
0mdb Feb 18, 2023
c5050be
dark bg to gray-700
0mdb Feb 18, 2023
c23273b
remove 2nd box from search
0mdb Feb 18, 2023
dd519e2
Merge branch 'frontend-react' of https://github.com/0mdb/collide into…
Feb 18, 2023
5fb6aa7
debounce search api calls .5 sec delay
0mdb Feb 18, 2023
3da1336
text colors -> muted
0mdb Feb 18, 2023
54f5c3b
Home2 -> home. Remove old Home and ForceGraphs
0mdb Feb 18, 2023
d043263
remove old Home from routing
0mdb Feb 18, 2023
e4c87eb
remove old Home from index
0mdb Feb 18, 2023
1ec574d
add typing
0mdb Feb 19, 2023
4a13e89
add chevron button to open search
0mdb Feb 19, 2023
7e48d6d
scale down graph size
0mdb Feb 19, 2023
b44dcf1
Merge branch 'frontend-react' of https://github.com/0mdb/collide into…
Feb 19, 2023
beef8d2
disabling strict mode fixed graph tearing
0mdb Feb 19, 2023
c163dae
remove oogly box shadow on icons in dark mode
0mdb Feb 19, 2023
7c2da5c
Add call to action section
0mdb Feb 19, 2023
3bc2244
set user reference to null explicitly
0mdb Feb 19, 2023
82b1d6b
try out call to action on landing
0mdb Feb 19, 2023
d763436
improve the way search displays result. disable autocomplete
0mdb Feb 19, 2023
506c022
Merge branch 'frontend-react' of https://github.com/0mdb/collide into…
Feb 20, 2023
bba063e
final search style WIP
0mdb Feb 20, 2023
0d262e9
clip vertical overflow
0mdb Feb 20, 2023
8acb387
add floating action button
0mdb Feb 21, 2023
d2a5409
add fab button to home
0mdb Feb 21, 2023
e168a75
Issue #21. Moving strings to dedicated file.
phaedrat Feb 21, 2023
f0b95fb
Issue #21. Importing strings. Working on colouring.
phaedrat Feb 21, 2023
5b9df4e
Issue #21. Text colours
phaedrat Feb 21, 2023
2bb0fd3
Issue #21. Button fill
phaedrat Feb 21, 2023
75f117b
Merge branch 'frontend-react' of https://github.com/collide-org/colli…
phaedrat Feb 21, 2023
42249f4
better styling on fab button
0mdb Feb 21, 2023
641e7ca
add highlighting for selected node and custom node info
0mdb Feb 21, 2023
763ee4d
padd darkMode to ForceGraph...darkmode still not working
0mdb Feb 21, 2023
a71ea45
add data type icons, remove user spaces from search match. match on v…
0mdb Feb 21, 2023
1e368a1
add tailwind font
0mdb Feb 21, 2023
0d3fa87
Merge branch 'frontend-react' of github.com:collide-org/collide into …
0mdb Feb 21, 2023
275a2e3
search icon opens search
0mdb Feb 21, 2023
e0b6ec0
scale the graph full width on moble
0mdb Feb 21, 2023
cb212ce
hide fab button until after first search
0mdb Feb 21, 2023
e1f69f4
fix bug with label disappearing on hover
0mdb Feb 21, 2023
1160589
fill bottom of emptygraph
0mdb Feb 21, 2023
1b4658e
update search icons to use data type icons
0mdb Feb 21, 2023
32e350c
formatting for force graph and empty graph
0mdb Feb 21, 2023
e444c3d
add legal policy page with boiler plate as starting point. #38
0mdb Feb 22, 2023
3470bad
add FAQ page. Needs copy #39
0mdb Feb 22, 2023
c8d5c68
add tailwind typography to unify fonts #21
0mdb Feb 22, 2023
fdb0c82
Add settings panel to home #40 .Resolves #32
0mdb Feb 22, 2023
99f149f
call to action page for #30 needs copy
0mdb Feb 22, 2023
ceda6f7
Update link in CTA to refer user to FAQ #24
0mdb Feb 22, 2023
8ef4042
Add user setting panel #40
0mdb Feb 22, 2023
3e889d8
Adjust canvas scale factor to 3/4 total window width. #41
0mdb Feb 22, 2023
9038aee
Remove unused tsx files #14
0mdb Feb 22, 2023
f144db8
Sign up for waiting list. Need API endpoint and email conf #30
0mdb Feb 22, 2023
618ed76
Adjustments but still wip. Now ignores spaces #34
0mdb Feb 22, 2023
3629733
All the remaining sections added back for review. #21
0mdb Feb 22, 2023
03153e4
Trying site name with no .io. #21
0mdb Feb 22, 2023
74ac5e0
Updated login working with API. Needs error checking. #29
0mdb Feb 22, 2023
d9d0f1a
Add contact form. Needs API #42
0mdb Feb 22, 2023
a60dc2a
Add about page. Maybe redundant with faq #39
0mdb Feb 22, 2023
0b1845e
Start of new login form. Will follow Register. #29
0mdb Feb 22, 2023
009dd89
Issue #33. Styling for remaining sections of Landing.
phaedrat Feb 23, 2023
650bb23
Password reset with form validation working. #44
0mdb Feb 23, 2023
8ccdf60
update api end point to use cookies fixes login #46
0mdb Feb 23, 2023
07977c0
replace login2 placeholder #46
0mdb Feb 23, 2023
9fc3845
user settings pulling what limited info we have #40
0mdb Feb 23, 2023
d7c9991
check for bad email before calling api #44
0mdb Feb 23, 2023
48842eb
Check for most things. Test on phone before closing issue #45
0mdb Feb 23, 2023
b607402
Issue #38. Adding license skeletons. Forcegraph done.
phaedrat Feb 24, 2023
be22513
Issue #38. Licenses/etc in. Formatting looking good.
phaedrat Feb 24, 2023
de3fc4e
Issue #39. Added FAQs. Fixed discovered issue with nav/footer colours…
phaedrat Feb 24, 2023
ea6cee3
add api client for user identity #40
0mdb Feb 24, 2023
3447594
write settings back to db WIP #40
0mdb Feb 24, 2023
a3e486b
try to store user identity in context on login WIP #46
0mdb Feb 24, 2023
7ceb33e
Merge branch 'frontend-react' of github.com:collide-org/collide into …
0mdb Feb 24, 2023
3471c30
Merge pull request #20 from collide-org/6-main-graph-profile-memgraph…
0mdb Feb 24, 2023
89beb95
Revert to async postgres. Kept graph query improvements. #50
0mdb Feb 25, 2023
08c6845
Merge branch 'frontend-react' of https://github.com/0mdb/collide into…
Feb 25, 2023
dbfea4c
Add back Items endpoints to adapt to user settings. #52
0mdb Feb 25, 2023
6b1b55c
adding restart on-failure for #53
Feb 25, 2023
0e898a1
Merge remote-tracking branch 'origin/frontend-react' into frontend-react
Feb 25, 2023
ce18f39
link to privacy policy #42
0mdb Feb 26, 2023
8722254
Merge branch 'frontend-react' of github.com:collide-org/collide into …
0mdb Feb 26, 2023
b77fe2f
fixes #48
0mdb Feb 26, 2023
01f31b1
doesnt fix #54 nests all contact, pw, forms etc. home not loading
0mdb Feb 26, 2023
496c16b
adding missed file #52
0mdb Feb 26, 2023
018dfd4
add is superuser dependency function for Depends #52
0mdb Feb 26, 2023
a6b1269
fix link to privacy policy #43
0mdb Feb 26, 2023
33b861d
Issue #51. Finally showing up without clipping. Improvements to come.
phaedrat Feb 26, 2023
b685cc5
Merge branch 'frontend-react' of https://github.com/collide-org/colli…
phaedrat Feb 26, 2023
6812664
fixes landing page on load #54
0mdb Feb 26, 2023
3969312
Merge branch 'frontend-react' of github.com:collide-org/collide into …
0mdb Feb 26, 2023
b1ce2ce
Comment out so container starts. Will replace. #52
0mdb Feb 26, 2023
1f2d9f8
Sorry!
phaedrat Feb 26, 2023
212468c
missed the nav/footer on this one #54
0mdb Feb 26, 2023
36bfee6
My turn for a sorry!
0mdb Feb 26, 2023
4429484
remove unused imports. #54
0mdb Feb 27, 2023
0e574b8
Seems to resolve #34 by removing static from options
0mdb Feb 27, 2023
d9eba48
remove instagram #21
0mdb Feb 27, 2023
60e8dcb
Issue #51. Centred. Unclear why SVG box is overflowing parent div.
phaedrat Feb 27, 2023
42f9db5
Merge branch 'frontend-react' of https://github.com/collide-org/colli…
phaedrat Feb 27, 2023
b2e2747
Page load with focus on input box to save a click. #29
0mdb Feb 27, 2023
bbdbce1
getting person/org/bill queries to happen from the search box
Feb 27, 2023
58bfa49
Store persist on client. Use get me endpoint to validate token #52
0mdb Feb 28, 2023
e76db7b
add protected routes
0mdb Feb 28, 2023
cc0a546
Finally getMe works with tokens #52
0mdb Feb 28, 2023
8a2a806
back to tokens. No more cookies! #52
0mdb Feb 28, 2023
d08cb3b
no more cookies pt 2. #52
0mdb Feb 28, 2023
8edd8e9
Add oAuth to user DB object. #52
0mdb Feb 28, 2023
2163c3a
Fix Networks link to point back home #21
0mdb Feb 28, 2023
5b25d42
Use local storage hook for darkmode setting #52
0mdb Feb 28, 2023
8f5d448
getting person/org/bill queries to happen from the search box
Feb 27, 2023
01571ac
Merge remote-tracking branch 'origin/unified_graphs' into unified_graphs
Mar 1, 2023
bec9bae
Issue #29. Styling of Login.
phaedrat Mar 1, 2023
e59c532
Merge branch 'frontend-react' of https://github.com/collide-org/colli…
phaedrat Mar 1, 2023
2fe6e12
Issue #58. Adding accents and hovers to secondary colours
phaedrat Mar 1, 2023
7af133b
Issue #29. Added logo to Register
phaedrat Mar 2, 2023
da968b6
Issue #58. Missing comma
phaedrat Mar 2, 2023
dc4f5ee
fixing the selected node visuals that I broke
Mar 2, 2023
cef8fec
Issue #29. Done-ish.
phaedrat Mar 2, 2023
00373b6
Merge pull request #59 from collide-org/unified_graphs
0mdb Mar 3, 2023
2181767
Issue #57. It really was just a well-placed z-index?
phaedrat Mar 3, 2023
780651b
Merge branch 'frontend-react' of https://github.com/collide-org/colli…
phaedrat Mar 3, 2023
84eba71
Fix search by node onClick by adding type, isbill to request. #36
0mdb Mar 3, 2023
e320f1d
Merge branch 'frontend-react' of github.com:collide-org/collide into …
0mdb Mar 3, 2023
5cca28e
change colide to lobbyradar in deply instructions #34
0mdb Mar 3, 2023
c782a84
Issue #51. Swapped out tailwind logo. Added one to navbar.
phaedrat Mar 4, 2023
dd1b52c
Merge branch 'frontend-react' of https://github.com/collide-org/colli…
phaedrat Mar 4, 2023
caf1866
Merge branch 'frontend-react' of github.com:collide-org/collide into …
0mdb Mar 4, 2023
da28f40
Add lobbyradar.io to CORS. #31
0mdb Mar 4, 2023
00b6fa7
Set landing to "Coming Soon" to test deploy on EC2 #31
0mdb Mar 4, 2023
1164ef8
put back landing page. Will test on new branch #31
0mdb Mar 4, 2023
a2d7284
Issue #63. Fancy enough damn it (for now).
phaedrat Mar 4, 2023
b659073
Merge branch 'frontend-react' of https://github.com/collide-org/colli…
phaedrat Mar 4, 2023
6a7e7ae
Issue #63. Added outline stroke (black)
phaedrat Mar 4, 2023
b16e286
Issue #63. Outline stroke in 50%/80%/90% shades from fill.
phaedrat Mar 4, 2023
b8d8046
Issue #47. Links to contact page.
phaedrat Mar 4, 2023
40f1789
disable items dependencies for now #52
0mdb Mar 4, 2023
9bb7a11
Setup to move settings to local #40 along with recent search #36
0mdb Mar 4, 2023
dd1d6cd
Merge branch 'frontend-react' of github.com:collide-org/collide into …
0mdb Mar 4, 2023
9b7b0ce
Issue #60. Nav sidebar closes onClick. I have no idea what I'm doing …
phaedrat Mar 4, 2023
de06e2d
Merge branch 'frontend-react' of https://github.com/collide-org/colli…
phaedrat Mar 4, 2023
5759324
Trying traefik tags with memgraph #31
0mdb Mar 4, 2023
fbf36c2
replace landing with coming soon #31
0mdb Mar 5, 2023
8d09f3c
memgraph-platform to memgraph #31
0mdb Mar 5, 2023
9dcc5e7
remove frontend depends_on #31
0mdb Mar 5, 2023
760906b
collide to lobbyradar.io #31
0mdb Mar 5, 2023
e5c8f24
initial working version
Mar 5, 2023
d819016
initial working version
Mar 5, 2023
b2a4ed9
some cleanup
Mar 5, 2023
d794f19
bit of cleanup
Mar 5, 2023
034a706
remove last of collide. troubleshooting deploy #31
0mdb Mar 5, 2023
a10f6f7
Issue #64. Progress on styling (text is visible at least!).
phaedrat Mar 5, 2023
fa9424c
Issue #64. Discovered similar input/text mismatch issue in Login.
phaedrat Mar 5, 2023
85d631b
add psycopg2 to pyproject #62
0mdb Mar 6, 2023
17cad84
back to docker-compose for troubleshooting #31
0mdb Mar 6, 2023
15157c4
Merge pull request #65 from collide-org/split_backend
jerodway Mar 6, 2023
f72f4a0
changing the display name for the black nodes
Mar 6, 2023
f3959b5
commenting out some printfs
Mar 6, 2023
d0b5d25
conditional icon in search box (just force and bills)
Mar 6, 2023
a84cb2f
Issue #64. Last of styling.
phaedrat Mar 6, 2023
d284b82
Merge branch 'frontend-react' of https://github.com/collide-org/colli…
phaedrat Mar 6, 2023
61f59f5
deploys
Mar 7, 2023
c3e673e
Merge branch 'frontend-react' into deploy-ec2
0mdb Mar 8, 2023
f9250a2
Merge branch 'deploy-ec2' of github.com:collide-org/collide into depl…
0mdb Mar 8, 2023
b616ee2
Merge pull request #69 from collide-org/deploy-ec2
0mdb Mar 8, 2023
e1296b7
clean up things I should have pre-merge #69
0mdb Mar 8, 2023
6d95180
builds and deploys on t2.large #70
0mdb Mar 9, 2023
27fa0a7
show back button on desktop view #40
0mdb Mar 9, 2023
716b214
hide unused notification button
0mdb Mar 9, 2023
6aeebe5
Clean up old auth strategy files #66
0mdb Mar 10, 2023
2d63d80
add aut kit, remove react-admin
0mdb Mar 10, 2023
4494632
simplify auth context handling with react-auth-kit
0mdb Mar 10, 2023
1bd78ce
use auth-kit for getting user settings
0mdb Mar 10, 2023
1243bbc
Update api to use react-auth-kit #52
0mdb Mar 10, 2023
4b963d8
update to auth-kit close #46
0mdb Mar 10, 2023
7418cf4
wrap entire app with AuthProvider #52
0mdb Mar 10, 2023
e33bd6c
remove unused imports #66
0mdb Mar 10, 2023
0ecb6b0
Good enough to close #45 also remove Remember Me.
0mdb Mar 10, 2023
663423d
Issue #71. Consistent styling.
phaedrat Mar 11, 2023
de9c8dc
Issue #72. Fixed it.
phaedrat Mar 11, 2023
f944ede
fix redirect after login from landing nav bar #46
0mdb Mar 11, 2023
09f78ea
email template for contact form #42
0mdb Mar 11, 2023
8d144b4
email templates for verifying new user emails #55
0mdb Mar 11, 2023
809ee1e
Send verify email on register. #55
0mdb Mar 11, 2023
76db458
Add types for validating emails #55
0mdb Mar 12, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
.vscode
.mypy_cache
docker-stack.yml
.dir-locals.el
20 changes: 10 additions & 10 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
image: tiangolo/docker-with-compose
image: tiangolo/docker-with-compose:2021-09-18

before_script:
- docker login -u gitlab-ci-token -p $CI_JOB_TOKEN $CI_REGISTRY
Expand Down Expand Up @@ -26,7 +26,7 @@ build-stag:
tags:
- build
- test

build-prod:
stage: build
script:
Expand All @@ -41,14 +41,14 @@ deploy-stag:
stage: deploy
script:
- >
DOMAIN=stag.collide.com
TRAEFIK_TAG=stag.collide.com
STACK_NAME=stag-collide-com
DOMAIN=stag.lobbyradar.io
TRAEFIK_TAG=stag.lobbyradar.io
STACK_NAME=stag-lobbyradar-io
TAG=stag
sh ./scripts/deploy.sh
environment:
name: staging
url: https://stag.collide.com
url: https://stag.lobbyradar.io
only:
- master
tags:
Expand All @@ -59,14 +59,14 @@ deploy-prod:
stage: deploy
script:
- >
DOMAIN=collide.com
TRAEFIK_TAG=collide.com
STACK_NAME=collide-com
DOMAIN=lobbyradar.io
TRAEFIK_TAG=lobbyradar.io
STACK_NAME=lobbyradar-io
TAG=prod
sh ./scripts/deploy.sh
environment:
name: production
url: https://collide.com
url: https://lobbyradar.io
only:
- production
tags:
Expand Down
76 changes: 38 additions & 38 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# collide
# lobbyradar

## Backend Requirements

Expand Down Expand Up @@ -307,36 +307,36 @@ Check all the corresponding available URLs in the section at the end.

If you are running Docker in an IP address different than `127.0.0.1` (`localhost`) and `192.168.99.100` (the default of Docker Toolbox), you will need to perform some additional steps. That will be the case if you are running a custom Virtual Machine, a secondary Docker Toolbox or your Docker is located in a different machine in your network.

In that case, you will need to use a fake local domain (`dev.collide.com`) and make your computer think that the domain is is served by the custom IP (e.g. `192.168.99.150`).
In that case, you will need to use a fake local domain (`dev.lobbyradar.io`) and make your computer think that the domain is is served by the custom IP (e.g. `192.168.99.150`).

If you used the default CORS enabled domains, `dev.collide.com` was configured to be allowed. If you want a custom one, you need to add it to the list in the variable `BACKEND_CORS_ORIGINS` in the `.env` file.
If you used the default CORS enabled domains, `dev.lobbyradar.io` was configured to be allowed. If you want a custom one, you need to add it to the list in the variable `BACKEND_CORS_ORIGINS` in the `.env` file.

* Open your `hosts` file with administrative privileges using a text editor:
* **Note for Windows**: If you are in Windows, open the main Windows menu, search for "notepad", right click on it, and select the option "open as Administrator" or similar. Then click the "File" menu, "Open file", go to the directory `c:\Windows\System32\Drivers\etc\`, select the option to show "All files" instead of only "Text (.txt) files", and open the `hosts` file.
* **Note for Mac and Linux**: Your `hosts` file is probably located at `/etc/hosts`, you can edit it in a terminal running `sudo nano /etc/hosts`.

* Additional to the contents it might have, add a new line with the custom IP (e.g. `192.168.99.150`) a space character, and your fake local domain: `dev.collide.com`.
* Additional to the contents it might have, add a new line with the custom IP (e.g. `192.168.99.150`) a space character, and your fake local domain: `dev.lobbyradar.io`.

The new line might look like:

```
192.168.99.100 dev.collide.com
192.168.99.100 dev.lobbyradar.io
```

* Save the file.
* **Note for Windows**: Make sure you save the file as "All files", without an extension of `.txt`. By default, Windows tries to add the extension. Make sure the file is saved as is, without extension.

...that will make your computer think that the fake local domain is served by that custom IP, and when you open that URL in your browser, it will talk directly to your locally running server when it is asked to go to `dev.collide.com` and think that it is a remote server while it is actually running in your computer.
...that will make your computer think that the fake local domain is served by that custom IP, and when you open that URL in your browser, it will talk directly to your locally running server when it is asked to go to `dev.lobbyradar.io` and think that it is a remote server while it is actually running in your computer.

To configure it in your stack, follow the section **Change the development "domain"** below, using the domain `dev.collide.com`.
To configure it in your stack, follow the section **Change the development "domain"** below, using the domain `dev.lobbyradar.io`.

After performing those steps you should be able to open: http://dev.collide.com and it will be server by your stack in `localhost`.
After performing those steps you should be able to open: http://dev.lobbyradar.io and it will be server by your stack in `localhost`.

Check all the corresponding available URLs in the section at the end.

### Change the development "domain"

If you need to use your local stack with a different domain than `localhost`, you need to make sure the domain you use points to the IP where your stack is set up. See the different ways to achieve that in the sections above (i.e. using Docker Toolbox with `local.dockertoolbox.tiangolo.com`, using `localhost.tiangolo.com` or using `dev.collide.com`).
If you need to use your local stack with a different domain than `localhost`, you need to make sure the domain you use points to the IP where your stack is set up. See the different ways to achieve that in the sections above (i.e. using Docker Toolbox with `local.dockertoolbox.tiangolo.com`, using `localhost.tiangolo.com` or using `dev.lobbyradar.io`).

To simplify your Docker Compose setup, for example, so that the API docs (Swagger UI) knows where is your API, you should let it know you are using that domain for development. You will need to edit 1 line in 2 files.

Expand Down Expand Up @@ -475,7 +475,7 @@ Then you need to have those constraints in your `docker-compose.yml` file for th
To be able to use different environments, like `prod` and `stag`, you should pass the name of the stack as an environment variable. Like:

```bash
STACK_NAME=stag-collide-com sh ./scripts/deploy.sh
STACK_NAME=stag-lobbyradar-io sh ./scripts/deploy.sh
```

To use and expand that environment variable inside the `docker-compose.yml` files you can add the constraints to the services like:
Expand Down Expand Up @@ -503,7 +503,7 @@ services:
deploy:
placement:
constraints:
- node.labels.collide-com.app-db-data == true
- node.labels.lobbyradar-io.app-db-data == true
```

**Note**: The `${STACK_NAME?Variable not set}` means "use the environment variable `STACK_NAME`, but if it is not set, show an error `Variable not set`".
Expand Down Expand Up @@ -555,13 +555,13 @@ then chose a node from the list. For example, `dog.example.com`.
* Add the label to that node. Use as label the name of the stack you are deploying followed by a dot (`.`) followed by the named volume, and as value, just `true`, e.g.:

```bash
docker node update --label-add collide-com.app-db-data=true dog.example.com
docker node update --label-add lobbyradar-io.app-db-data=true dog.example.com
```

* Then you need to do the same for each stack version you have. For example, for staging you could do:

```bash
docker node update --label-add stag-collide-com.app-db-data=true cat.example.com
docker node update --label-add stag-lobbyradar-io.app-db-data=true cat.example.com
```

### Deploy to a Docker Swarm mode cluster
Expand Down Expand Up @@ -605,16 +605,16 @@ TAG=prod FRONTEND_ENV=production bash ./scripts/build-push.sh
3. **Deploy your stack**

* Set these environment variables:
* `DOMAIN=collide.com`
* `TRAEFIK_TAG=collide.com`
* `STACK_NAME=collide-com`
* `DOMAIN=lobbyradar.io`
* `TRAEFIK_TAG=lobbyradar.io`
* `STACK_NAME=lobbyradar-io`
* `TAG=prod`
* Use the provided `scripts/deploy.sh` file with those environment variables:

```bash
DOMAIN=collide.com \
TRAEFIK_TAG=collide.com \
STACK_NAME=collide-com \
DOMAIN=lobbyradar.io \
TRAEFIK_TAG=lobbyradar.io \
STACK_NAME=lobbyradar-io \
TAG=prod \
bash ./scripts/deploy.sh
```
Expand Down Expand Up @@ -703,33 +703,33 @@ These are the URLs that will be used and generated by the project.

Production URLs, from the branch `production`.

Frontend: https://collide.com
Frontend: https://lobbyradar.io

Backend: https://collide.com/api/
Backend: https://lobbyradar.io/api/

Automatic Interactive Docs (Swagger UI): https://collide.com/docs
Automatic Interactive Docs (Swagger UI): https://lobbyradar.io/docs

Automatic Alternative Docs (ReDoc): https://collide.com/redoc
Automatic Alternative Docs (ReDoc): https://lobbyradar.io/redoc

PGAdmin: https://pgadmin.collide.com
PGAdmin: https://pgadmin.lobbyradar.io

Flower: https://flower.collide.com
Flower: https://flower.lobbyradar.io

### Staging URLs

Staging URLs, from the branch `master`.

Frontend: https://stag.collide.com
Frontend: https://stag.lobbyradar.io

Backend: https://stag.collide.com/api/
Backend: https://stag.lobbyradar.io/api/

Automatic Interactive Docs (Swagger UI): https://stag.collide.com/docs
Automatic Interactive Docs (Swagger UI): https://stag.lobbyradar.io/docs

Automatic Alternative Docs (ReDoc): https://stag.collide.com/redoc
Automatic Alternative Docs (ReDoc): https://stag.lobbyradar.io/redoc

PGAdmin: https://pgadmin.stag.collide.com
PGAdmin: https://pgadmin.stag.lobbyradar.io

Flower: https://flower.stag.collide.com
Flower: https://flower.stag.lobbyradar.io

### Development URLs

Expand Down Expand Up @@ -771,19 +771,19 @@ Traefik UI: http://local.dockertoolbox.tiangolo.com:8090

Development URLs, for local development.

Frontend: http://dev.collide.com
Frontend: http://dev.lobbyradar.io

Backend: http://dev.collide.com/api/
Backend: http://dev.lobbyradar.io/api/

Automatic Interactive Docs (Swagger UI): https://dev.collide.com/docs
Automatic Interactive Docs (Swagger UI): https://dev.lobbyradar.io/docs

Automatic Alternative Docs (ReDoc): https://dev.collide.com/redoc
Automatic Alternative Docs (ReDoc): https://dev.lobbyradar.io/redoc

PGAdmin: http://dev.collide.com:5050
PGAdmin: http://dev.lobbyradar.io:5050

Flower: http://dev.collide.com:5555
Flower: http://dev.lobbyradar.io:5555

Traefik UI: http://dev.collide.com:8090
Traefik UI: http://dev.lobbyradar.io:8090

### Development in localhost with a custom domain URLs

Expand Down
1 change: 1 addition & 0 deletions backend/app/.gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
.mypy_cache
.coverage
htmlcov
search.ipynb
36 changes: 31 additions & 5 deletions backend/app/app/api/api_v1/api.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,35 @@
from fastapi import APIRouter

from app.api.api_v1.endpoints import items, login, users, utils
# from app.api.api_v1.endpoints import items, resfresh
from app.api.api_v1.endpoints import resfresh
from app.core.users import auth_backend, fastapi_users
from app.schemas.user import UserCreate, UserRead, UserUpdate

api_router = APIRouter()
api_router.include_router(login.router, tags=["login"])
api_router.include_router(users.router, prefix="/users", tags=["users"])
api_router.include_router(utils.router, prefix="/utils", tags=["utils"])
api_router.include_router(items.router, prefix="/items", tags=["items"])
api_router.include_router(resfresh.router, prefix="/auth", tags=["auth"])

api_router.include_router(
fastapi_users.get_auth_router(auth_backend), prefix="/auth/jwt", tags=["auth"]
)
api_router.include_router(
fastapi_users.get_register_router(UserRead, UserCreate),
prefix="/auth",
tags=["auth"],
)
api_router.include_router(
fastapi_users.get_reset_password_router(),
prefix="/auth",
tags=["auth"],
)
api_router.include_router(
fastapi_users.get_verify_router(UserRead),
prefix="/auth",
tags=["auth"],
)
api_router.include_router(
fastapi_users.get_users_router(UserRead, UserUpdate),
prefix="/users",
tags=["users"],
)

# api_router.include_router(items.router, prefix="/items", tags=["items"])
1 change: 1 addition & 0 deletions backend/app/app/api/api_v1/endpoints/items.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
router = APIRouter()



@router.get("/", response_model=List[schemas.Item])
def read_items(
db: Session = Depends(deps.get_db),
Expand Down
96 changes: 0 additions & 96 deletions backend/app/app/api/api_v1/endpoints/login.py

This file was deleted.

Loading