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

openSUSE / agama / 7927478251
72%

Build:
DEFAULT BRANCH: master
Ran 16 Feb 2024 07:42AM UTC
Jobs 3
Files 671
Run time 35s
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: 73.938% (-0.09%) from 74.031%
7927478251

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

1404 of 2168 branches covered (64.76%)

Branch coverage included in aggregate %.

16361 of 21859 relevant lines covered (74.85%)

22.39 hits per line

Subprojects
ID Flag name Job ID Ran Files Coverage
1 rust 7927478251.1 16 Feb 2024 07:42AM UTC 72
40.22
GitHub Action Run
1 web 7913824761.1 15 Feb 2024 09:38AM UTC 289
73.18
GitHub Action Run
1 service 7870597187.1 12 Feb 2024 10:50AM UTC 310
84.98
GitHub Action Run
Source Files on build 7927478251
  • Tree
  • List 671
  • Changed 121
  • Source Changed 8
  • Coverage Changed 16
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Github Actions Build #7927478251
  • 0a2e7b63 on github
  • Prev Build on master (#7913824761)
  • Next Build on master (#7975321865)
  • 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