• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

openSUSE / agama / 7927478251 / 1 – rust
72%
master: 72%

Build:
DEFAULT BRANCH: master
Ran 16 Feb 2024 07:42AM UTC
Files 72
Run time 1s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

16 Feb 2024 07:37AM UTC coverage: 40.223%. First build
rust – 7927478251.1

push

github

web-flow
Add a basic web server (#1041)

Trello:
https://trello.com/c/msRHsnpV/3570-3-build-a-basic-agama-web-server

This PR introduces the web server for [Agama's 2024
architecture](https://github.com/openSUSE/agama/blob/master/doc/new_architecture.md).
At this point, it implements:

* A `/ping` endpoint.
* A simple WebSocket to receive progress events. It is just a
proof-of-concept and even the format should be adapted.
* Tracing/logging.

Additionally, it is able to export the description of the API using
[OpenAPI](https://www.openapis.org/).

## Usage

The new binary implements two subcommands: `serve` and `openapi`.

### Running the server

```
$ agama-web-server serve --help
Start the API server

Usage: agama-web-server serve [OPTIONS]

Options:
      --address <ADDRESS>  Address to listen on (default: "0.0.0.0:3000") [default: 0.0.0.0:3000]
  -h, --help               Print help
```

### Generating the OpenAPI documentation

```
$ agama-web-sever openapi
{
  "openapi": "3.0.3",
  "info": {
    "title": "agama-dbus-server",
    "description": "Agama web API description",
    "license": {
      "name": ""
    },
    "version": "0.1.0"
  },
...
```


Additionally, it adds a new `agama-web-server` package to the RPM spec
file.

## To do

- [x] Improve logging/tracing.
- [x] Expose the API documentation (openAPI?).

## Out of scope

* Better error handling.
* Read the D-Bus address from `/run/agama/bus`. We should do pretty much
the same for `agama-cli`.

## Testing

- Added a new Rus integration test
- Tested manually

1335 of 3319 relevant lines covered (40.22%)

1.27 hits per line

Source Files on job rust - 7927478251.1
  • Tree
  • List 72
  • Changed 0
  • Source Changed 0
  • Coverage Changed 0
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 7927478251
  • 0a2e7b63 on github
  • Prev Job for on master (#7913824761.)
  • Next Job for on master (#7975321865.1)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc