Skip to content
This repository has been archived by the owner on Jul 15, 2024. It is now read-only.

Commit

Permalink
v1.0.0-rc.0
Browse files Browse the repository at this point in the history
  • Loading branch information
mobileoverlord committed Feb 28, 2018
1 parent 6205fe5 commit c20a0d5
Show file tree
Hide file tree
Showing 12 changed files with 186 additions and 106 deletions.
7 changes: 2 additions & 5 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
defaults: &defaults
working_directory: /nerves/build
docker:
- image: nervesproject/nerves:0.17.0
- image: nervesproject/nerves:1.0.0-rc.0
environment:
ENV: CI
MIX_ENV: test
MIX_TARGET: x86_64
ELIXIR_VERSION: 1.5.2
ELIXIR_VERSION: 1.6.1

install_elixir: &install_elixir
run:
Expand All @@ -20,15 +19,13 @@ install_hex_rebar: &install_hex_rebar
run:
name: Install hex and rebar
command: |
cd /tmp
mix local.hex --force
mix local.rebar --force
install_nerves_bootstrap: &install_nerves_bootstrap
run:
name: Install nerves_bootstrap
command: |
cd /tmp
mix archive.install github nerves-project/nerves_bootstrap --force
version: 2.0
Expand Down
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# Changelog

## v1.0.0-rc.0

* Updated Dependencies
* [nerves_system_br v1.0.0-rc.0](https://github.com/nerves-project/nerves_system_br/releases/tag/v1.0.0-rc.0)
* [nerves_toolchain v1.0.0-rc.0](https://github.com/nerves-project/toolchains/releases/tag/v1.0.0-rc.0)
* [nerves v1.0.0-rc.0](https://github.com/nerves-project/nerves/releases/tag/v1.0.0-rc.0)

## v0.6.0

* Updated Dependencies
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.6.0
1.0.0-rc.0
4 changes: 2 additions & 2 deletions example/config/config.exs
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,10 @@ config :nerves, :firmware,

# Add the LoggerCircularBuffer backend. This removes the
# default :console backend.
config :logger, backends: [LoggerCircularBuffer]
config :logger, backends: [RingLogger]

# Set the number of messages to hold in the circular buffer
config :logger, LoggerCircularBuffer, buffer_size: 100
config :logger, RingLogger, buffer_size: 100

network_ssid = System.get_env("NERVES_NETWORK_SSID")
network_psk = System.get_env("NERVES_NETWORK_PSK")
Expand Down
25 changes: 20 additions & 5 deletions example/lib/example/application.ex
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,14 @@ defmodule Example.Application do
import Supervisor.Spec, warn: false
iface = Application.get_env(:nerves_network, :iface)
init0()
# Comment if you need to wait for an IP before launching
init1(%{})
# Define workers and child supervisors to be supervised
children = [
worker(SystemRegistry.Task, [
[:state, :network_interface, iface, :ipv4_address],
&init1/1])
# Uncomment if you need to wait for IP
# worker(SystemRegistry.Task, [
# [:state, :network_interface, iface, :ipv4_address],
# &init1/1])
]

# See http://elixir-lang.org/docs/stable/elixir/Supervisor.html
Expand Down Expand Up @@ -61,7 +64,15 @@ defmodule Example.Application do
def init_ui() do
System.put_env("QTWEBENGINE_REMOTE_DEBUGGING", "9222")
System.put_env("QTWEBENGINE_CHROMIUM_FLAGS", "--disable-embedded-switches")
System.cmd("qt-webengine-kiosk", ["-c", "/etc/qt-webengine-kiosk.ini", "--opengl", "NATIVE"])
start_remote_debugger()
# Need to spawn to make sure we don't block
# Otherwise, SystemRegistry will continue to send messages
# and run out of memory.
if pid = Process.whereis(QtWebEngineKiosk) do
Process.exit(pid, :normal)
end
spawn(fn -> MuonTrap.cmd("qt-webengine-kiosk", ["-c", "/etc/qt-webengine-kiosk.ini", "--opengl", "NATIVE"]) end)
|> Process.register(QtWebEngineKiosk)
end

def init_ntp(ntp_server) do
Expand All @@ -75,6 +86,10 @@ defmodule Example.Application do
end

def start_remote_debugger() do
System.cmd("socat", ["tcp-listen:9223,fork", "tcp:localhost:9222"])
if pid = Process.whereis(QtWebEngineRemoteDebugger) do
Process.exit(pid, :normal)
end
spawn(fn -> MuonTrap.cmd("socat",["tcp-listen:9223,fork", "tcp:localhost:9222"]) end)
|> Process.register(QtWebEngineRemoteDebugger)
end
end
8 changes: 5 additions & 3 deletions example/mix.exs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
defmodule Example.MixProject do
use Mix.Project

System.put_env("MIX_TARGET", "x86_64")
@target System.get_env("MIX_TARGET") || "host"

def project do
Expand All @@ -9,7 +10,7 @@ defmodule Example.MixProject do
version: "0.1.0",
elixir: "~> 1.4",
target: @target,
archives: [nerves_bootstrap: "~> 0.8"],
archives: [nerves_bootstrap: "~> 1.0-rc"],
deps_path: "deps/#{@target}",
build_path: "_build/#{@target}",
lockfile: "mix.lock.#{@target}",
Expand Down Expand Up @@ -45,8 +46,8 @@ defmodule Example.MixProject do
# Run "mix help deps" to learn about dependencies.
defp deps do
[
{:nerves, "~> 0.10", runtime: false},
{:logger_circular_buffer, "~> 0.2"}
{:nerves, "~> 1.0-rc", runtime: false},
{:ring_logger, "~> 0.4"}
] ++ deps(@target)
end

Expand All @@ -59,6 +60,7 @@ defmodule Example.MixProject do
{:nerves_runtime, "~> 0.4"},
{:nerves_network, "~> 0.3"},
{:nerves_init_gadget, "~> 0.1"},
{:muontrap, "~> 0.2"}
] ++ system(target)
end

Expand Down
10 changes: 6 additions & 4 deletions example/mix.lock.x86_64
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,19 @@
"elixir_make": {:hex, :elixir_make, "0.4.0", "992f38fabe705bb45821a728f20914c554b276838433349d4f2341f7a687cddf", [:mix], [], "hexpm"},
"logger_circular_buffer": {:hex, :logger_circular_buffer, "0.2.0", "fd3dfd4720ef9e26a20e1d405d4bfbd6b88507e2fb0cccbe00a1fff38862e5ca", [:mix], [], "hexpm"},
"mdns": {:hex, :mdns, "0.1.7", "7b949773ff5809bb720256171767db1c9bf21eea477128b361a92b0c5e6af220", [:mix], [{:dns, "~> 1.0", [hex: :dns, repo: "hexpm", optional: false]}], "hexpm"},
"nerves": {:hex, :nerves, "0.10.0", "8558b661f92acb1c01689bb1b750362c58733ac4305aa305ce418b2ed2af3f20", [:mix], [{:distillery, "~> 1.4", [hex: :distillery, repo: "hexpm", optional: false]}], "hexpm"},
"muontrap": {:hex, :muontrap, "0.2.1", "ecf61fd9265c186f8f8fe6014aa054c61e1fc36ed3f7ab9db35a9d13ee808d5a", [:make, :mix], [{:elixir_make, "~> 0.4", [hex: :elixir_make, repo: "hexpm", optional: false]}], "hexpm"},
"nerves": {:hex, :nerves, "1.0.0-rc.0", "5c6cf122611d0024d06b88593aa9af46180d30712fc6ff07fa25fb9100125f1e", [:mix], [{:distillery, "~> 1.4", [hex: :distillery, repo: "hexpm", optional: false]}], "hexpm"},
"nerves_firmware_ssh": {:hex, :nerves_firmware_ssh, "0.3.1", "e8b1967fa0aff255230be539c68ec868d33884193a385caff957ebad7d6aa8af", [:mix], [{:nerves_runtime, "~> 0.4", [hex: :nerves_runtime, repo: "hexpm", optional: false]}], "hexpm"},
"nerves_init_gadget": {:hex, :nerves_init_gadget, "0.2.1", "20f36dd062fb00e2be8817ddff1b9ced9762877cfe23f6ec1d5936a37e3fc2c8", [:mix], [{:mdns, "~> 0.1", [hex: :mdns, repo: "hexpm", optional: false]}, {:nerves_firmware_ssh, "~> 0.2", [hex: :nerves_firmware_ssh, repo: "hexpm", optional: false]}, {:nerves_network, "~> 0.3", [hex: :nerves_network, repo: "hexpm", optional: false]}, {:nerves_runtime, "~> 0.3", [hex: :nerves_runtime, repo: "hexpm", optional: false]}], "hexpm"},
"nerves_network": {:hex, :nerves_network, "0.3.6", "c95779283ace071e9d12882d6a80e31edc8c476012adc61aba2ff6c306ef97b3", [:make, :mix], [{:elixir_make, "~> 0.4", [hex: :elixir_make, repo: "hexpm", optional: false]}, {:nerves_network_interface, "~> 0.4.0", [hex: :nerves_network_interface, repo: "hexpm", optional: false]}, {:nerves_wpa_supplicant, "~> 0.3.0", [hex: :nerves_wpa_supplicant, repo: "hexpm", optional: false]}, {:system_registry, "~> 0.4", [hex: :system_registry, repo: "hexpm", optional: false]}], "hexpm"},
"nerves_network_interface": {:hex, :nerves_network_interface, "0.4.4", "200b1a84bc1a7fdeaf3a1e0e2d4e9b33e240b034e73f39372768d43f8690bae0", [:make, :mix], [{:elixir_make, "~> 0.4", [hex: :elixir_make, repo: "hexpm", optional: false]}], "hexpm"},
"nerves_runtime": {:hex, :nerves_runtime, "0.5.3", "7447a3e718762f3901046f72cc824e528f8d0565a581b8ae58f4f5b6436bca7f", [:make, :mix], [{:elixir_make, "~> 0.4", [hex: :elixir_make, repo: "hexpm", optional: false]}, {:system_registry, "~> 0.5", [hex: :system_registry, repo: "hexpm", optional: false]}], "hexpm"},
"nerves_system_br": {:hex, :nerves_system_br, "0.17.0", "f7c0d1b6b11e9a1c187b17f2401a00956bebd5c45946bfe2a332ad26ecbf18f9", [:mix], [], "hexpm"},
"nerves_system_br": {:hex, :nerves_system_br, "1.0.0-rc.0", "63400e1a12baa307603d9d0b30fe87de1f67623f71156b278f0be5ce74c7d117", [:mix], [], "hexpm"},
"nerves_system_linter": {:hex, :nerves_system_linter, "0.3.0", "84e0f63c8ac196b16b77608bbe7df66dcf352845c4e4fb394bffd2b572025413", [:mix], [], "hexpm"},
"nerves_toolchain_ctng": {:hex, :nerves_toolchain_ctng, "1.3.1", "add96a4b12da4b50fdc5cf18517989de37cf3b329d7edf258ec794878ba06e89", [:mix], [{:nerves, "~> 0.9", [hex: :nerves, repo: "hexpm", optional: false]}], "hexpm"},
"nerves_toolchain_x86_64_unknown_linux_gnu": {:hex, :nerves_toolchain_x86_64_unknown_linux_gnu, "0.13.1", "41979823c60bbc6808f40ab61048ccab48a432b5ff268f1c87f9e1edd9621fd9", [:mix], [{:nerves, "~> 0.9", [hex: :nerves, repo: "hexpm", optional: false]}, {:nerves_toolchain_ctng, "~> 1.3", [hex: :nerves_toolchain_ctng, repo: "hexpm", optional: false]}], "hexpm"},
"nerves_toolchain_ctng": {:hex, :nerves_toolchain_ctng, "1.4.0-rc.0", "1766752c2a854af5e0f102892d947f787f8f47ee500f564e7fdb50c4d1c4789c", [:mix], [{:nerves, "~> 1.0-rc", [hex: :nerves, repo: "hexpm", optional: false]}], "hexpm"},
"nerves_toolchain_x86_64_unknown_linux_gnu": {:hex, :nerves_toolchain_x86_64_unknown_linux_gnu, "1.0.0-rc.0", "885b813d416ca9428b81def8a45c6abdb16618ec3a87351f7964e297064d2f7d", [:mix], [{:nerves, "~> 1.0-rc", [hex: :nerves, repo: "hexpm", optional: false]}, {:nerves_toolchain_ctng, "~> 1.4-rc", [hex: :nerves_toolchain_ctng, repo: "hexpm", optional: false]}], "hexpm"},
"nerves_wpa_supplicant": {:hex, :nerves_wpa_supplicant, "0.3.2", "19dc7e1248336e7f542b11b2b857ceb5b088d3eb41a6ca75b7b76628dcf67aad", [:make, :mix], [{:elixir_make, "~> 0.3", [hex: :elixir_make, repo: "hexpm", optional: false]}], "hexpm"},
"ring_logger": {:hex, :ring_logger, "0.4.0", "d58b2d9be6350d291fde90c734dcd56cb50b9be7cae4868163088db84a499e92", [:mix], [], "hexpm"},
"shoehorn": {:hex, :shoehorn, "0.2.0", "6aa80804145c545c59af01980d255209483b14826f53411b4a8797b24c323c20", [:mix], [{:distillery, "~> 1.0", [hex: :distillery, repo: "hexpm", optional: false]}], "hexpm"},
"socket": {:hex, :socket, "0.3.13", "98a2ab20ce17f95fb512c5cadddba32b57273e0d2dba2d2e5f976c5969d0c632", [:mix], [], "hexpm"},
"system_registry": {:hex, :system_registry, "0.7.0", "cd3aaf2c15392fa60f93869dde49f536fcf60e54f3b15db737e7d4ebcac108f4", [:mix], [], "hexpm"},
Expand Down
51 changes: 22 additions & 29 deletions mix.exs
Original file line number Diff line number Diff line change
@@ -1,10 +1,3 @@
if Mix.env == :test do
hash = :os.cmd('git rev-parse HEAD')
|> to_string
|> String.trim
System.put_env("NERVES_FW_VCS_IDENTIFIER", hash)
end

defmodule KioskSystemx8664.Mixfile do
use Mix.Project

Expand Down Expand Up @@ -36,17 +29,16 @@ defmodule KioskSystemx8664.Mixfile do
]
end

# Starting nerves_bootstrap adds the required aliases to Mix.Project.config()
# Aliases are only added if MIX_TARGET is set.
def bootstrap(args) do
Application.start(:nerves_bootstrap)
Mix.Task.run("loadconfig", args)
end

def application do
[]
end

defp bootstrap(args) do
System.put_env("MIX_TARGET", "x86_64")
Application.start(:nerves_bootstrap)
Mix.Task.run("loadconfig", args)
end

defp nerves_package do
[
type: :system,
Expand All @@ -64,9 +56,9 @@ defmodule KioskSystemx8664.Mixfile do

defp deps do
[
{:nerves, "~> 0.10", runtime: false},
{:nerves_system_br, "~> 0.17.0", runtime: false, app: false},
{:nerves_toolchain_x86_64_unknown_linux_gnu , "~> 0.13.1", runtime: false},
{:nerves, "~> 1.0-rc", runtime: false},
{:nerves_system_br, "~> 1.0-rc", runtime: false},
{:nerves_toolchain_x86_64_unknown_linux_gnu , "~> 1.0-rc", runtime: false},
{:nerves_system_linter, "~> 0.3.0", runtime: false}
]
end
Expand All @@ -88,24 +80,25 @@ defmodule KioskSystemx8664.Mixfile do

defp package_files do
[
"LICENSE",
"mix.exs",
"nerves_defconfig",
"README.md",
"VERSION",
"package",
"patches",
"priv",
"rootfs_overlay",
"fwup.conf",
"CHANGELOG.md",
"Config.in",
"external.mk",
"fwup-revert.conf",
"fwup.conf",
"grub.cfg",
"LICENSE",
"linux-4.13.defconfig",
"post-createfs.sh",
"mix.exs",
"nerves_defconfig",
"post-build.sh",
"Config.in",
"external.mk",
"package",
"post-createfs.sh",
"README.md",
"users_table.txt",
"priv",
"patches"
"VERSION"
]
end
end
8 changes: 4 additions & 4 deletions mix.lock
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
%{
"distillery": {:hex, :distillery, "1.5.2", "eec18b2d37b55b0bcb670cf2bcf64228ed38ce8b046bb30a9b636a6f5a4c0080", [:mix], [], "hexpm"},
"nerves": {:hex, :nerves, "0.10.0", "8558b661f92acb1c01689bb1b750362c58733ac4305aa305ce418b2ed2af3f20", [:mix], [{:distillery, "~> 1.4", [hex: :distillery, repo: "hexpm", optional: false]}], "hexpm"},
"nerves_system_br": {:hex, :nerves_system_br, "0.17.0", "f7c0d1b6b11e9a1c187b17f2401a00956bebd5c45946bfe2a332ad26ecbf18f9", [:mix], [], "hexpm"},
"nerves": {:hex, :nerves, "1.0.0-rc.0", "5c6cf122611d0024d06b88593aa9af46180d30712fc6ff07fa25fb9100125f1e", [:mix], [{:distillery, "~> 1.4", [hex: :distillery, repo: "hexpm", optional: false]}], "hexpm"},
"nerves_system_br": {:hex, :nerves_system_br, "1.0.0-rc.0", "63400e1a12baa307603d9d0b30fe87de1f67623f71156b278f0be5ce74c7d117", [:mix], [], "hexpm"},
"nerves_system_linter": {:hex, :nerves_system_linter, "0.3.0", "84e0f63c8ac196b16b77608bbe7df66dcf352845c4e4fb394bffd2b572025413", [:mix], [], "hexpm"},
"nerves_toolchain_ctng": {:hex, :nerves_toolchain_ctng, "1.3.1", "add96a4b12da4b50fdc5cf18517989de37cf3b329d7edf258ec794878ba06e89", [:mix], [{:nerves, "~> 0.9", [hex: :nerves, repo: "hexpm", optional: false]}], "hexpm"},
"nerves_toolchain_x86_64_unknown_linux_gnu": {:hex, :nerves_toolchain_x86_64_unknown_linux_gnu, "0.13.1", "41979823c60bbc6808f40ab61048ccab48a432b5ff268f1c87f9e1edd9621fd9", [:mix], [{:nerves, "~> 0.9", [hex: :nerves, repo: "hexpm", optional: false]}, {:nerves_toolchain_ctng, "~> 1.3", [hex: :nerves_toolchain_ctng, repo: "hexpm", optional: false]}], "hexpm"},
"nerves_toolchain_ctng": {:hex, :nerves_toolchain_ctng, "1.4.0-rc.0", "1766752c2a854af5e0f102892d947f787f8f47ee500f564e7fdb50c4d1c4789c", [:mix], [{:nerves, "~> 1.0-rc", [hex: :nerves, repo: "hexpm", optional: false]}], "hexpm"},
"nerves_toolchain_x86_64_unknown_linux_gnu": {:hex, :nerves_toolchain_x86_64_unknown_linux_gnu, "1.0.0-rc.0", "885b813d416ca9428b81def8a45c6abdb16618ec3a87351f7964e297064d2f7d", [:mix], [{:nerves, "~> 1.0-rc", [hex: :nerves, repo: "hexpm", optional: false]}, {:nerves_toolchain_ctng, "~> 1.4-rc", [hex: :nerves_toolchain_ctng, repo: "hexpm", optional: false]}], "hexpm"},
"nerves_toolchain_x86_64_unknown_linux_musl": {:hex, :nerves_toolchain_x86_64_unknown_linux_musl, "0.11.0", "15adde7a5df1d35d0f3f9c46cc3784c2d5e4f2b3a5bff7023f33b7799ddef997", [:mix], [{:nerves, "~> 0.7", [hex: :nerves, repo: "hexpm", optional: false]}, {:nerves_toolchain_ctng, "~> 1.1", [hex: :nerves_toolchain_ctng, repo: "hexpm", optional: false]}], "hexpm"},
}
2 changes: 1 addition & 1 deletion nerves_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ BR2_x86_64=y
BR2_GLOBAL_PATCH_DIR="${BR2_EXTERNAL_NERVES_PATH}/patches ${NERVES_DEFCONFIG_DIR}/patches"
BR2_TOOLCHAIN_EXTERNAL=y
BR2_TOOLCHAIN_EXTERNAL_DOWNLOAD=y
BR2_TOOLCHAIN_EXTERNAL_URL="https://github.com/nerves-project/toolchains/releases/download/v0.13.1/nerves_toolchain_x86_64_unknown_linux_gnu-linux_x86_64-0.13.1-84C2F9843BFD6792AAD3F14436F084A1D0953AF88525684D326A1FC20C5E0B20.tar.xz"
BR2_TOOLCHAIN_EXTERNAL_URL="https://github.com/nerves-project/toolchains/releases/download/v1.0.0-rc.0/nerves_toolchain_x86_64_unknown_linux_gnu-linux_x86_64-1.0.0-rc.0-7328AFD.tar.xz"
BR2_TOOLCHAIN_EXTERNAL_CUSTOM_PREFIX="$(ARCH)-unknown-linux-gnu"
BR2_TOOLCHAIN_EXTERNAL_GCC_6=y
BR2_TOOLCHAIN_EXTERNAL_HEADERS_4_10=y
Expand Down
2 changes: 1 addition & 1 deletion rootfs_overlay/etc/erlinit.config
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
-e LANG=en_US.UTF-8;LANGUAGE=en;ERL_INETRC=/etc/erl_inetrc;ERL_CRASH_DUMP=/root/crash.dump

# Mount the application partition
-m /dev/rootdisk3:/root:ext4::
-m /dev/rootdisk0p4:/root:ext4::

# Erlang release search path
-r /srv/erlang
Expand Down
Loading

0 comments on commit c20a0d5

Please sign in to comment.