backend

command module
v1.2.1 Latest Latest
Warning

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

Go to latest
Published: May 1, 2025 License: AGPL-3.0 Imports: 32 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README ΒΆ

GitHub Release Go Reference Code coverage License Maintained yes

Green Ecolution Backend 🌿

Smart irrigation is essential to saving water, reducing staff workload, and cutting costs. This project provides the backend for Green Ecolution β€” a digital system to manage urban greenery efficiently.

πŸ‘‰ For the frontend implementation, visit the Green Ecolution Frontend.

The backend acts as the interface between the website and the database, managing data about:

  • 🌳 Trees
  • 🌿 Tree clusters
  • πŸ“‘ Sensors
  • πŸ—ΊοΈΒ Watering plans
  • πŸš› Vehicles
  • πŸ‘€ Users

In the current setup, sensors are connected to a microcontroller with an LoRaWAN modules. Sensor data is transmitted via LoRaWAN to an MQTT gateway, then forwarded to the server for processing.

Developed in collaboration with TBZ Flensburg, this software is designed to be adaptable for other cities. It originated as a research project within the Applied Computer Science Master's program at the University of Applied Sciences Flensburg.

For further information, visit:

Quick Start Guide πŸš€

To quickly run the application locally:

  1. Download the Docker Compose configuration:
wget https://raw.githubusercontent.com/green-ecolution/backend/refs/heads/develop/.docker/docker-compose.yaml
  1. Build and launch the application containers:
docker compose up

By default, external services like auth, mqtt, routing, and s3 are disabled but can be enabled via configuration. See the Demo Setup for more details.

πŸ‘‰ Once the service is up and running, you can access it at: http://localhost:8123

Technologies Used βš™οΈ

Local Development Setup πŸ’»

For a detailed step-by-step guide on setting up your local development environment, refer to the Local Development Wiki πŸ“–.

Prerequisites
Initial Setup βš™οΈ

Install required tools:

make setup

Generate code:

make generate

Start the infrastructure services using Docker Compose. This setup includes:

  • a local PostgreSQL database,
  • routing services such as Valhalla, ORS and VROOM for route and vehicle scheduling calculations
make infra/up
Running the Project ▢️

With live reload:

make run/live

Without live reload:

make run

πŸ‘‰ Once the service is up and running, you can access it at: http://localhost:3000

How to Contribute 🀝

We welcome contributions! Please follow these guidelines:

  1. Fork this repository.
  2. Create a topic branch off develop.
  3. Commit your changes.
  4. Push your branch to your fork.
  5. Open a Pull Request.

This project follows:

Thank you for helping us improve Green Ecolution! 🌿

Documentation ΒΆ

The Go Gopher

There is no documentation for this package.

Directories ΒΆ

Path Synopsis
internal
worker
Package worker implements an event management system for publishing and subscribing to events.
Package worker implements an event management system for publishing and subscribing to events.
pkg
client module
plugin module

Jump to

Keyboard shortcuts

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