Closed DFurnes closed 4 years ago
Only thing I couldn't track down (a n3w day, a n3w n00b question), where do we specify if
local
vss3
storage driver is used in dev vs. prod?
Oops, forgot to expose an environment variable for that! It's the filesystems.default
config var.
Added the ability to swap that with the STORAGE_DRIVER
environment variable in 2c73356.
{
"click_id": "w48OKyE-ea8658bc-c7c5-467f-9203-c68c5d92a850",
"shortened": "w48OKyE",
"target_url": "https://www.dfurnes.com",
"click_time": "2020-05-14T15:50:57.244Z",
"user_agent": "curl/7.69.1"
}
trying to pad your dfurnes.com google analytics eh? 🤔
trying to pad your dfurnes.com google analytics eh? 🤔
Gotta get that SEO!!
What's this PR do?
This pull request updates our "visit link" route to write click events to our storage bucket, using the same schema as rows in our existing PostgreSQL clicks database:
Here's an example of one of those click log files:
How should this be reviewed?
🍃 Cleanup: I extracted the Dynamoose model config into
config/database.js
in 5a29624.💾 I installed & configured Flydrive, a Flysystem-inspired storage driver for Node.js. This allows us to write these files to disk on local development, and to an S3 bucket in production.
📝 Finally, I added the code to write these click logs in ebc63d1.
Any background context you want to provide?
Yes, I'm shamelessly trying to re-build Laravel (or at least Lumen) in Node.js. 😇
Relevant tickets
References Pivotal #172799447.
Checklist