Phoenix Phinally Phuctioning (Day 111)
May 11, 2022•319 words
Total hours: 226.600
Top three:
1) Google Social Provider
Finally got it working!!! It was a snap after I got the API setup and the integration perfectly redirected to auth.mygaya.day!!!!! I’m sooo happy!!!
This is something that has taken waaaay longer than I expected but I’m soo happy that I managed to get it working.
Why do I have to jump thru all of these hoops?? It prevents a malicious redirection to another site to then capture the token and then redirect to the legitimate domain.
Something that I never actually thought of or even realized was a threat until now.
2) Update Documentation for Auth0 and Google
This is important. Having good, consistent and easily readable and searchable documentation ensures the following:
- Codifies the knowledge
- Outlines likely what to do in unknown circumstances
- Sets a precedent to continue documenting well
Finally it also causes slow down and reviewing what was done. Having a second look and writing it out for someone else to read (even if it’s just you in the future), means that you’ll often review or even tweak the idea. Result?? Leading to better code overall!!!!
3) Fly for Deployment.
Using Fly.io (Launching is as simple as fly launch and a few commands. EVEN sets secrets and such and manages the database for me!!!)
More than willing to pay money to have another group manage this middle layer of abstraction. I was doing it myself and I was getting stuck. Docker isn’t knowledge that I should need to focus on.
Plus it manages certificate, redirection and prevents accessing NON secure connection :star eyes: It’s totally worth it!!!!
I went with Fly.io instead of gigaelixir because Fly provided raw IP address (instead of CNAME).
It’s working beautifully as my root domain.
Plus entire deployment process managed fully by Fly.io. Down to the certificate, IP addresses and everything in between :heart: