Coder Social home page Coder Social logo

oh-my-gate-iot-executor's Introduction

Oh My Gate IOT Executor

Build Status

Receive msg related to IOT actions to be executed via google Pub/Sub and handles them.

important This service doesn't create a topic if not exists. Please be sure to create it in GCP. The subscription absence is handled.

Expected message shape

{
	"action": "Open",
	"id": 2
}

Available IOT adapters

This service is able to support the following adapters:

  • Standard out: simply prints msg to standard_out.
  • gpio: interacts with a gpio board (example: Raspberry Pi) The adapter can be configured using the environment variable: ADAPTER_TYPE

Envs needed

  • GOOGLE_APPLICATION_CREDENTIALS: Path where gcp service account is placed. Here you can find a way to create it.

  • GCP_PROJECT_ID: Name of project id.

  • SUBSCRIPTION_NAME: Name of the subscription to use to listen for msgs.

  • TOPIC_NAME: Name of the topic to use to listen for msgs.

  • ACK_TIME_IN_SECONDS: Ack time to use in seconds by msg broker

  • ADAPTER_TYPE: Adapter type to use to handle messages. Available values are:

    • standard_out
    • gpio

CI/CD:

This repo has a set of pipeline in order to produce artifacts in an automatic way: Docker hub image

  • on branch != main an image with tag dev is published
  • on branch == main an image with tag latest is pubblished
  • on tag an image with tag-name is published

How to publish a docker image for different architectures

Perform make cross_build

How to release a new service version

  • git checkout master
  • git tag {your tag}
  • git push --follow-tags

oh-my-gate-iot-executor's People

Contributors

massicer avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.