example: Add example of user authencate l2 switch like an AP on cafe
This commit is contained in:
parent
0b92a325d5
commit
4949376e3a
5 changed files with 70 additions and 0 deletions
5
examples/cafe/.formatter.exs
Normal file
5
examples/cafe/.formatter.exs
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
# Used by "mix format"
|
||||
[
|
||||
inputs: ["mix.exs", "config/*.exs"],
|
||||
subdirectories: ["apps/*"]
|
||||
]
|
||||
21
examples/cafe/.gitignore
vendored
Normal file
21
examples/cafe/.gitignore
vendored
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
# The directory Mix will write compiled artifacts to.
|
||||
/_build/
|
||||
|
||||
# If you run "mix test --cover", coverage assets end up here.
|
||||
/cover/
|
||||
|
||||
# The directory Mix downloads your dependencies sources to.
|
||||
/deps/
|
||||
|
||||
# Where third-party dependencies like ExDoc output generated docs.
|
||||
/doc/
|
||||
|
||||
# Ignore .fetch files in case you like to edit your project deps locally.
|
||||
/.fetch
|
||||
|
||||
# If the VM crashes, it generates a dump, let's ignore it too.
|
||||
erl_crash.dump
|
||||
|
||||
# Also ignore archive artifacts (built via "mix archive.build").
|
||||
*.ez
|
||||
|
||||
4
examples/cafe/README.md
Normal file
4
examples/cafe/README.md
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
# Cafe
|
||||
|
||||
**TODO: Add description**
|
||||
|
||||
20
examples/cafe/config/config.exs
Normal file
20
examples/cafe/config/config.exs
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
# This file is responsible for configuring your application
|
||||
# and its dependencies with the aid of the Mix.Config module.
|
||||
use Mix.Config
|
||||
|
||||
# By default, the umbrella project as well as each child
|
||||
# application will require this configuration file, as
|
||||
# configuration and dependencies are shared in an umbrella
|
||||
# project. While one could configure all applications here,
|
||||
# we prefer to keep the configuration of each individual
|
||||
# child application in their own app, but all other
|
||||
# dependencies, regardless if they belong to one or multiple
|
||||
# apps, should be configured in the umbrella to avoid confusion.
|
||||
import_config "../apps/*/config/config.exs"
|
||||
|
||||
# Sample configuration (overrides the imported configuration above):
|
||||
#
|
||||
# config :logger, :console,
|
||||
# level: :info,
|
||||
# format: "$date $time [$level] $metadata$message\n",
|
||||
# metadata: [:user_id]
|
||||
20
examples/cafe/mix.exs
Normal file
20
examples/cafe/mix.exs
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
defmodule Cafe.MixProject do
|
||||
use Mix.Project
|
||||
|
||||
def project do
|
||||
[
|
||||
apps_path: "apps",
|
||||
start_permanent: Mix.env() == :prod,
|
||||
deps: deps()
|
||||
]
|
||||
end
|
||||
|
||||
# Dependencies listed here are available only for this
|
||||
# project and cannot be accessed from applications inside
|
||||
# the apps folder.
|
||||
#
|
||||
# Run "mix help deps" for examples and options.
|
||||
defp deps do
|
||||
[]
|
||||
end
|
||||
end
|
||||
Loading…
Add table
Add a link
Reference in a new issue