Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
52 commits
Select commit Hold shift + click to select a range
54a6710
Changed src folder name
imggion Jun 8, 2025
5a6b01b
Update Cargo.toml files to configure workspace and add new docker crate
imggion Jun 9, 2025
6f44cfb
Add Docker client implementation with data structures and API methods
imggion Jun 9, 2025
4142e9f
Add Docker module with Unix socket connection tests
imggion Jun 9, 2025
77324f0
Add Docker API request handling and response parsing
imggion Jun 9, 2025
e4846f8
Add Docker API endpoint handlers for version, containers, and volumes
imggion Jun 9, 2025
a1e4959
Add docker crate dependency in Cargo.toml
imggion Jun 9, 2025
d521c2c
Refactor Docker client for improved error handling and macOS support
imggion Jun 9, 2025
486e624
Enhance Docker API with container details endpoint
imggion Jun 9, 2025
37403d8
Add Docker API endpoints for version, containers, and volumes
imggion Jun 9, 2025
2e2b29c
Add Docker module to webserver and create handlers file
imggion Jun 10, 2025
99e3298
Optimize release profile settings in Cargo.toml
imggion Jun 15, 2025
4fed1a8
Add REFERENCES.md for Docker API documentation
imggion Jun 15, 2025
cbcdb9b
Refactor Docker API structures for improved label handling and networ…
imggion Jun 15, 2025
e838932
Remove unused reqwest client and simplify response parsing in Docker …
imggion Jun 15, 2025
dfa3437
Enhance TeusRequestBuilder to support optional query parameters in AP…
imggion Jun 15, 2025
31b85e5
Remove unused import from handlers.rs file in the Teus configuration …
imggion Jun 15, 2025
5028f13
Refactor test cases in parser.rs to remove mutable temp file declarat…
imggion Jun 15, 2025
ad6cb38
Add dead code annotations for unused fields in Config and ServerConfi…
imggion Jun 16, 2025
85ab186
Remove unused import of std::fs in storage.rs test module
imggion Jun 16, 2025
93af9ea
Add dead code annotations for unused structs in sys.rs
imggion Jun 16, 2025
7e9ce44
Remove unused import from api.rs file to enhance code clarity
imggion Jun 16, 2025
ed561fb
Remove unused imports from handlers.rs to improve code clarity
imggion Jun 16, 2025
4c6a8a2
Format test code in monitor system module
imggion Jun 22, 2025
d42fbce
Add sysd crate and update project dependencies
imggion Jun 22, 2025
504d790
Add comprehensive type documentation for Docker API structs
imggion Jun 22, 2025
94ab13e
Add comprehensive documentation for auth module
imggion Jun 22, 2025
9663c6f
Add query params support for Docker container listing
imggion Jun 22, 2025
8dc70d5
Add detailed API documentation and improve code organization
imggion Jun 22, 2025
ae7f92f
Add extended container struct for detailed container info
imggion Jun 23, 2025
d1c987d
Add bookmark management functionality to backend
imggion Jun 23, 2025
5e5c692
Add Docker container inspect response types
imggion Jun 23, 2025
a1f2844
Add bookmark module and API endpoints
imggion Jun 23, 2025
9f5dc8f
Make get_service_by_id private and unused
imggion Jun 26, 2025
bdb667d
Add auth check endpoint
imggion Jun 26, 2025
c735d6b
Add teus-dashboard submodule
imggion Jun 28, 2025
ea3bd9a
Add DELETE and PATCH endpoints for bookmark services
imggion Jun 28, 2025
6c3aadd
Add Zed editor task definitions
imggion Jun 28, 2025
16d547f
Fix code formatting and style issues
imggion Jun 28, 2025
4e767c8
Add musl target config for Linux static builds
imggion Jun 28, 2025
d52cca4
Create rust.yml
imggion Jun 30, 2025
f33cacc
Remove redundant blank line in docker.rs
imggion Jun 30, 2025
5c88b40
Merge branch 'feat/docker-sock-listener' of https://github.com/gdjohn…
imggion Jun 30, 2025
1ee4340
Comment out sysd crate from workspace members
imggion Jun 30, 2025
634a155
Fix import order in systeminfo.rs
imggion Jun 30, 2025
d038146
Remove trailing whitespace from model docs
imggion Jun 30, 2025
ce318a1
Format Rust code using Rustfmt
imggion Jun 30, 2025
b24448f
Make container response fields optional
imggion Jun 30, 2025
52bae6d
Rename CI workflow job for clarity
imggion Jun 30, 2025
9ce8e51
Consolidate module imports into single use statement
imggion Jun 30, 2025
ca19815
Create docker-openapi.yaml
imggion Jun 30, 2025
552e278
Improve ContainerInspectResponse struct documentation
imggion Jul 1, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
53 changes: 53 additions & 0 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
name: Rust Teus CI
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]

env:
CARGO_TERM_COLOR: always

jobs:
teus-build-checks:
runs-on: ubuntu-latest
steps:
# 1. Checkout the repository code
- name: Checkout repository
uses: actions/checkout@v4

# 2. toolchain
- name: Setup Rust toolchain
uses: dtolnay/rust-toolchain@stable
with:
components: clippy, rustfmt

# 3. cache
- name: Cache Cargo dependencies
uses: actions/cache@v4
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-cargo-

# 4. formatting
- name: Check formatting
run: cargo fmt -- --check

# 5. clippy (is it necessary?)
- name: Run Clippy
run: cargo clippy -- -D warnings

# 6. tests
- name: Run tests
run: cargo test --verbose

# 7. release
- name: Build in release mode
run: cargo build --verbose --release
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "dashboard"]
path = dashboard
url = https://github.com/imggion/teus-dashboard
32 changes: 32 additions & 0 deletions .zed/tasks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
[
{
"label": "Run Teus - Debug",
"command": "cargo run",
//"args": [],
"env": {},
"use_new_terminal": false,
// Whether to allow multiple instances of the same task to be run, or rather wait for the existing ones to finish, defaults to `false`.
"allow_concurrent_runs": false,
"reveal": "always",
"hide": "never",
"shell": "system",
"show_summary": true,
"show_output": true,
"tags": []
},
{
"label": "Test workspace",
"command": "cargo test --workspaces",
//"args": [],
"env": {},
"use_new_terminal": false,
// Whether to allow multiple instances of the same task to be run, or rather wait for the existing ones to finish, defaults to `false`.
"allow_concurrent_runs": false,
"reveal": "always",
"hide": "never",
"shell": "system",
"show_summary": true,
"show_output": true,
"tags": []
}
]
33 changes: 30 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,14 +1,25 @@
[workspace]
# This file is part of the Teus project.
members = ["crates/docker"]
# members = ["crates/docker", "crates/sysd"] # add this when sysd is in developing state
default-members = ["."]

[package]
name = "teus"
version = "0.1.0"
edition = "2024"
authors = ['gdjohn4s']
edition = "2021"
authors = ['immgion']

[dependencies]
[lib]
name = "teus"
path = "teus/lib.rs"

[[bin]]
name = "teus"
path = "./teus/main.rs"

[dependencies] # we need to clean something here
docker = { path = "crates/docker"}
diesel = { version = "2.2.0", features = ["sqlite", "returning_clauses_for_sqlite_3_35"] }
dotenvy = "0.15"
actix-cors = "0.7.0"
Expand All @@ -19,6 +30,22 @@ derive_more = { version = "2.0.1", features = ["display", "error", "from"] }
jsonwebtoken = "9.3.1"
rusqlite = "0.34.0"
serde = { version = "1.0.218", features = ["derive"] }
serde_json = "1.0"
serde_qs = "0.13"
sysinfo = "0.33.1"
toml = "0.8.20"
argon2 = "0.5.3"

[dev-dependencies]
tempfile = "3.8"
tokio-test = "0.4"

[profile.release]
opt-level = "z" # Optimize for size
lto = true # Enable link-time optimization
strip = true # Strip symbols from binary
panic = "abort" # Abort on panic instead of unwinding
codegen-units = 1 # Reduce parallel code generation units

[target.x86_64-unknown-linux-musl]
linker = "x86_64-linux-musl-gcc"
2 changes: 2 additions & 0 deletions REFERENCES.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
### Documentations
- [Docker API](https://docs.docker.com/reference/api/engine/version/v1.50/)
10 changes: 10 additions & 0 deletions crates/docker/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
[package]
name = "docker"
version = "0.1.0"
edition = "2021"

[dependencies]
reqwest = { version = "0.12", features = ["json"] } # Or latest version, "json" feature is handy
tokio = { version = "1", features = ["macros", "rt-multi-thread"] }
serde = { version = "1.0.218", features = ["derive"] }
serde_json = "1.0"
Loading
Loading