quazar

quazar

Suggestion for new app architecture

I am planning a new app which will have web app and desktop desktop counterpart using electron. This would be my first production phoenix project and also first electron project. I would love some suggestion from experience people who has worked with this or similar stacks. Below is my planned tech stack, if possible please share your experience, best practices and tech advice.

  • API written in phoenix framework
  • Authentication using Guardian
  • Web app build with angular 6
  • Electron app with angular 6
  • Webpack for asset management
  • No channels for now but will implement it later for fast search.

I’ll need some advice on

  • How to manage frontend angular assets for phoenix and electron. Its one of my main concern. Duplication can turn into nightmare.
  • API versioning to so I can deploy web app daily while update desktop app less frequently.
  • Website will have some public content part that should be visible to public, search engines and fast to load. I am not sure angular is best fit for such content. If I separate it out as plain html, it would create duplication. Server side rendering is possible with phoenix? If possible how’s your experience with it? I haven’t worked with anything beyond angularjs 1.2 and new version has changed a lot.
  • How do you deploy phoenix? I have a build server on linode 1 GB instance and its super slow. Takes around 20-25 min to build release.

Any suggestions are welcome…

Most Liked

kokolegorille

kokolegorille

It seems You have already choosen your stack, but let me give You my 2 kopecks…

  • You can use Absinthe/GraphQL as API
  • You can use Phoenix Token instead of Guardian
  • Definitively use channels, there is good js support

But as always… it depends on situation :slight_smile:

PS: I build release on a Linux box, similar to the one I deploy too, and just transfer the tar file.

sribe

sribe

Most of it (the ERTS runtime) is the same every time. Expand locally and rsync up (with z flag), you’ll be moving very little data.

LostKobrakai

LostKobrakai

There not even need to expand something. Distillery can skip the compressing step and just update the plain files in the release folder.

Where Next?

Popular in Questions Top

JDanielMartinez
Hi! May someone helps me, please! I have two apps into an umbrella project: the first one is Database, which manages queries, and the se...
New
sergio
In Ruby, I can go: User.find_by(email: "foobar@email.com").update(email: "hello@email.com") How can I do something similar in Elixir? ...
New
pmjoe
I have a relationship of love and hate with Elixir. Lots of things are just absolutely right, but there are some things that are kind of ...
New
sergio_101
I am VERY much an elixir newbie. I have taken one elixir course and one phoenix course on Udemy. During that course, I saw the instructor...
New
fireproofsocks
I’m working on defining a simple Ecto schema for a table (in PostGres), but I don’t see where I can define a column as NOT NULL. Conside...
New
sacepums
Hey guys. I'm new to elixir and im really stocked about it. But I ran into a bit of problem - I need to convert a date sting, for examp...
New
vertexbuffer
Hello, can anybody help here..? I have a list of players and I what to delete an element, but every for loop the list is reverting to ori...
New
script
If I have a string “1000 cfu/ml” . I want to remove the characters and / and space . So the string is like this "1000" What is the ...
New
vac
Hi, I'm quite new in Elixir and I'm trying to format a string to a PEM format. I have the certificate value like MIIDBTCCAe2...... and ...
New
wernerlaude
In AR this is so simple @articles = current_user.articles How to do in Ecto? def index(conn, _params) do current_user = conn.assig...
New

Other popular topics Top

chrismccord
Phoenix 1.4.0 released Phoenix 1.4 is out! This release ships with exciting new features, most notably with HTTP2 support, improved deve...
688 30048 115
New
yurko
Here are few pieces of (common) Linux knowledge that we use for reasonably small one server apps. We use Ubuntu but this should work for ...
New
William
I would like to know that is there any online source for learning Phoenix Framework for building E-Commerce Store? Any advantage on build...
New
_russellb
I want to try my hand at web scraping. What tools/libraries do I need to use. I’m hoping to turn this into something professional so don’...
New
Harrisonl
We have an ECS cluster with 4 services, where each task joins a single cluster, via discovery ECS discovery service. Currently when I de...
New
lk-geimfari
What is most correct way to open, read and parse JSON file with poison? For example if we have example.json file in root of some projec...
New
aadeshere1
I have a another noob question about loop. Since elixir is immutable, while loop is not directly possible. total = 10 while total != 0 ...
New
fayddelight
I tried installing elixir 1.11.2 erlang 23.3.4 via asdf in my zsh shell. Enabled the versions locally and globally. When I list them ...
New
Patoshizzle
After calling mix ecto.create I get this error: 17:00:32.162 [error] GenServer #PID<0.412.0> terminating ** (Postgrex.Error) FATAL...
New
AstonJ
by Lance Halvorsen Elixir and Phoenix are generating tremendous excitement as an unbeatable platform for building modern web application...
460 27162 124
New

We're in Beta

About us Mission Statement