magmad

command
v0.0.0-...-89602ce Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 18, 2020 License: BSD-3-Clause Imports: 16 Imported by: 0

README

magmad service

facebookincubator

magmad service is a core part of magma gateway platform, it is required on every gateway and facilitates the following gateway functionality:

  • Maintaining and displaying unique gateway identity information necessary for the gateway register on and join a network
  • Bootstraping gateway on the network and maintaining gateway's client certificates
  • Checking in with the cloud and providing the cloud with up to date gateway status
  • Monitoring gateway services, collecting and publishing the services' and system metrics to the cloud
  • Creating and maintaining secure cloud to gateway RPC channel for real time cloud requests fulfilment
  • Delivering and maintaining of cloud controlled gateway services' configuration
  • Providing gateway control APIs to the cloud, such as:
    • starting/stopping gateway services
    • rebooting gateway
    • running network diagnostics
    • remote execution of permitted commands
    • etc.

Implementation

This is Go native implementation of magmad service, it is intended as a 'drop in' replacement of python based magmad service on systems with limited resources or lack of full python support. It'll work with all existing magmad.yml, service_registry.yml and control_proxy.yml configurations located in /etc/magma/configs or legacy /etc/magma directories.

Current implementation requires at least 15MB of RAM and 3MB of storage (compressed) on most supported systems/architectures.

Building magmad

magmad binary can be built on any system with installed Go tools. Go1.12 or later is recommended.

To build:

  • Clone magma github repository
  • (optional) Create a target directory for magmad binary (example: mkdir -p ~/bin/arm; mkdir -p ~/bin/amd64)
  • cd magma/gateway/go
  • Use Go tool to build magmad for your target platform. Examples:
    • GOOS=linux GOARCH=arm go build -o ~/bin/arm/ magma/gateway/services/magmad
    • GOOS=linux GOARCH=amd64 go build -o ~/bin/amd64/ magma/gateway/services/magmad
  • To reduce magmad binary size, you may use the following options:
    • GOOS=linux GOARCH=arm go build -o ~/bin/arm/magmad.prod -ldflags="-s -w" magma/gateway/services/magmad
    • You can also use upx to compress the binary:
      • upx --brute -o ~/bin/arm/magmad ~/bin/arm/magmad.prod

Supported Architectures & Systems

magmad is a Go native, statically-linked application. It should be compatible with all supported by Go distributions. As of go1.14 the supported distributions are:

  • android/386
  • android/amd64
  • android/arm
  • android/arm64
  • darwin/386
  • darwin/amd64
  • darwin/arm
  • darwin/arm64
  • dragonfly/amd64
  • freebsd/386
  • freebsd/amd64
  • freebsd/arm
  • freebsd/arm64
  • illumos/amd64
  • js/wasm
  • linux/386
  • linux/amd64
  • linux/arm
  • linux/arm64
  • linux/mips
  • linux/mips64
  • linux/mips64le
  • linux/mipsle
  • linux/ppc64
  • linux/ppc64le
  • linux/riscv64
  • linux/s390x
  • netbsd/386
  • netbsd/amd64
  • netbsd/arm
  • netbsd/arm64
  • openbsd/386
  • openbsd/amd64
  • openbsd/arm
  • openbsd/arm64
  • plan9/386
  • plan9/amd64
  • plan9/arm
  • solaris/amd64
  • windows/386
  • windows/amd64
  • windows/arm

Join the Magma Community

See the CONTRIBUTING file for how to help out.

License

Magma is BSD License licensed, as found in the LICENSE file. The EPC is OAI is offered under the OAI Apache 2.0 license, as found in the LICENSE file in the OAI directory.

Documentation

Overview

Copyright 2020 The Magma Authors.

This source code is licensed under the BSD-style license found in the LICENSE file in the root directory of this source tree.

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Directories

Path Synopsis
package service implements magmad GRPC service
package service implements magmad GRPC service
generic_command
package generic_command implements magmad shell command execution functionality
package generic_command implements magmad shell command execution functionality
ping
package ping implements magmad ping execution functionality
package ping implements magmad ping execution functionality
* Copyright 2020 The Magma Authors.
* Copyright 2020 The Magma Authors.
package status implements magmad status amd metrics collectors & reporters package status implements magmad status amd metrics collectors & reporters package status implements magmad status collector & reporter package status implements magmad status amd metrics collectors & reporters
package status implements magmad status amd metrics collectors & reporters package status implements magmad status amd metrics collectors & reporters package status implements magmad status collector & reporter package status implements magmad status amd metrics collectors & reporters

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL