We’ve been working on a ‘Summer of Elixir’ as a mini series for our podcast JavaScript to Elm. A show that usually covers, well Elm, and other functional topics from the perspective of a JS developer. The goal is to build and deploy a small application with Elixir to learn and share our experience. The first 2 episodes are available
So far it’s been pretty enjoyable, with only mild frustrations. We’d love feedback, tips, resources. Anything you’ve got that might help us along the way. Check back for new episodes until summer’s over, or we get our project built!
You can subscribe here and follow along: Podcast Feed
I just started listening to the Elixir Deployment podcast and noticed a mention about Google App Engine not supporting WebSockets (called sockets in the podcasts for some reason). This is already solved, see here: Elixir | Google Cloud Platform
Anyway, I am currently trying to do the same CI/CD pipeline with GCP + Kubernetes, so I am really looking forward to the rest of that episode.
App-Enggine WebSocket Support As of Feb 2019, it looks like we’re good to go. That coupled with the $30/month bill we would incur when our gcp credits ran out, this switch seems to make a lot of sense.
We’ve finally getting into some of the actual Elixir now that our CI/CD is all set up and it’s a blast!!!
Checkout the progress, and look for the full rundown about it this week.
Trying to get my Phoenix deployment on GCP App Engine to force or redirect to the SSL connection. Currently you can connect to both http and https. I’ve seen a couple options
Just fyi, we ended up setting up our pipeline with GitHub as a repo + pull requests -> GitLab CI for CI, checks, etc. -> Gigalixir for deployment. I would love to use GitHub Actions to avoid GitLab as another layer of complexity, but unfortunately, we’re still waiting for the public beta approval or for final release. As for Gigalixir, It’s lot easier to create, scale and mainly destroy an app compared to Google App Engine.
I use Gitlab CI at work for source and all the pipeline work, it’s a really good solution. I feel you having it and github adds unwelcome overhead. Knowing what I know now about gcp app engine and where this project ended up, I too would have gone with Gigalixir to help remove a lot of the complexity around create, scale, and destroy. I just came realize I have to manually destroy old instances of app engine, maybe?
I would absolutely take another look at Elm. It’s giving me wider exposure to static types, type theory, functional programming, and really the got me to branch out from a full stack in JavaScript. It’s a great community that I really enjoy.
Making life a little easier with ecto migrations on prod release with distillery.
release :postit do
set version: current_version(:postit)
set applications: [
:runtime_tools
]
set commands: [
"migrate": "rel/commands/migrate.sh"
]
end
We started out with plans to add some routes and additional models, but fell down the rabbit hole trying to answer this question: How do i reuse a function in multiple controllers? In this specific instance, we’ll want to secure multiple routes, but don’t want to copy / paste the secure function we have to every controller, that will get out of hand fast!
A 2019-07-28T23:28:17Z Running migrations for postit
A 2019-07-28T23:28:17Z 2019/07/28 23:28:17 New connection for "post-it-243617:us-central1:postitdb-beta"
A 2019-07-28T23:28:17Z 2019/07/28 23:28:17 New connection for "post-it-243617:us-central1:postitdb-beta"
A 2019-07-28T23:28:18Z 23:28:18.294 [info] == Running 20190717045929 Postit.Repo.Migrations.CreatePosts.change/0 forward
A 2019-07-28T23:28:18Z 23:28:18.298 [info] create table posts
A 2019-07-28T23:28:18Z 23:28:18.371 [info] == Migrated 20190717045929 in 0.0s
We’ve moved on from the default Phoenix page. It served us well, the project is starting to take on some real personality. We’re just getting into the good stuff!!
Tackle a little bit of devs ops to start, getting Ecto migrations working on ‘post_boot’ hook on release from Distillery. With that in place we can start to dig into the domain of our application and start making some meaningful changes. Also, checkout the new styling!!!1