Skip to content

gigalixir/flame_gigalixir_backend

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

FLAMEGigalixirBackend

A FLAME Backend for Gigalixir, Elixir’s Platform as a Service.

Module Version Last Updated

Hex Docs Total Download License

Installation

def deps do
  [
    {:flame_gigalixir_backend, "~> 0.1.0"}
  ]
end

Usage

Configure the FLAME backend

Configure the flame backend in our configuration or application setup:

  # config/prod.exs
  config :flame, :backend, FLAMEGigalixirBackend

Configure clustering

The backend relies on libcluster to communicate between the FLAME Parent and the FLAME workers.

  # config/runtime.exs
  config :libcluster,
    topologies: [
      k8s_example: [
        strategy: Cluster.Strategy.Kubernetes,
        config: [
          kubernetes_selector: System.get_env("LIBCLUSTER_KUBERNETES_SELECTOR"),
          kubernetes_node_basename: System.get_env("LIBCLUSTER_KUBERNETES_NODE_BASENAME")]]]

Be sure to start up libclustering:

  # application.ex
  def start(_type, _args) do
    topologies = Application.get_env(:libcluster, :topologies) || []

    children = [
      {Cluster.Supervisor, [topologies, [name: MyApplication.ClusterSupervisor]]},
      ...
    ]
    ...
  end

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages