dockerfile for server
This commit is contained in:
@@ -0,0 +1,8 @@
|
|||||||
|
FROM rust:alpine as builder
|
||||||
|
WORKDIR /usr/src/smalltalk
|
||||||
|
COPY . .
|
||||||
|
RUN cargo build -p server --release
|
||||||
|
|
||||||
|
FROM alpine:latest
|
||||||
|
COPY --from=builder /usr/src/smalltalk/target/release/server /usr/local/bin/smalltalk
|
||||||
|
CMD ["smalltalk"]
|
||||||
@@ -1,24 +1,17 @@
|
|||||||
# smalltalk
|
# smalltalk
|
||||||
|
|
||||||
## build and run client
|
## running server
|
||||||
|
|
||||||
Usage:
|
### using docker
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
cargo run -p client --release -- --server-ip <SERVER_IP>
|
docker build -t smalltalk .
|
||||||
|
docker run -d --rm -p 6767:6767/tcp -p 6767:6767/udp --name smalltalk smalltalk
|
||||||
```
|
```
|
||||||
|
|
||||||
Options:
|
### using cargo
|
||||||
|
|
||||||
```
|
before, open port `6767` tcp and udp
|
||||||
-s, --server-ip <SERVER_IP>
|
|
||||||
-h, --help Print help
|
|
||||||
-V, --version Print version
|
|
||||||
```
|
|
||||||
|
|
||||||
## build and run server
|
|
||||||
|
|
||||||
before, open port `8080` tcp/udp
|
|
||||||
|
|
||||||
Usage:
|
Usage:
|
||||||
|
|
||||||
@@ -29,17 +22,23 @@ cargo run -p server --release -- [OPTIONS]
|
|||||||
Options:
|
Options:
|
||||||
|
|
||||||
```
|
```
|
||||||
-s, --server-ip <SERVER_IP> [default: 0.0.0.0:8080]
|
-s, --server-ip <SERVER_IP> [default: 0.0.0.0:6767]
|
||||||
-h, --help Print help
|
-h, --help Print help
|
||||||
-V, --version Print version
|
-V, --version Print version
|
||||||
```
|
```
|
||||||
|
|
||||||
---
|
## build and run client
|
||||||
|
|
||||||
I think it will be based on:
|
Usage:
|
||||||
|
|
||||||
- `tokio`: async and network connection
|
```bash
|
||||||
- `cpal`: raw audio input and output
|
cargo run -p client --release -- --server-ip <SERVER_IP>
|
||||||
- `opus`: encoding and decoding audio stream
|
```
|
||||||
- `ffmpeg-next`: capturing, encoding and decoding video stream
|
|
||||||
- `egui` + `eframe`: ui
|
Options:
|
||||||
|
```
|
||||||
|
-c, --connect-with-defaults <CONNECT_WITH_DEFAULTS>
|
||||||
|
-s, --server-ip <SERVER_IP>
|
||||||
|
-h, --help Print help
|
||||||
|
-V, --version Print version
|
||||||
|
```
|
||||||
|
|||||||
Reference in New Issue
Block a user