Skip to content

Hello, IceRPC

This repository contains the source code for icerpc://hello.icerpc.dev — a publicly available IceRPC server intended for the testing and development of IceRPC clients.

Available Services

The following services are mapped to their default service paths and are available using the TCP and QUIC transports on the default port (4062):

ServicePathDescriptionExample Clients
Slice Greeter/VisitorCenter.GreeterA simple service that greets visitorsC# Slice Secure
C# Slice QUIC
Protobuf Greeter/visitor_center.GreeterA simple service that greets visitorsC# Protobuf Secure
C# Protobuf QUIC
Slice Stream/StreamExample.GeneratorA service that streams dataC# Slice Stream
Protobuf Stream/stream_example.GeneratorA service that streams dataC# Protobuf Stream

Running the server using Docker

The hello server is available as a Docker image on Docker Hub. The server requires TLS certificates to run, so you will need to provide the server certificate and private key. This repository contains a set of self-signed certificates that can be used for testing purposes.

The default server certificate and private key paths are /certs/server_cert.pem and /certs/server_key.pem respectively. These paths can be overridden using the SERVER_CERT and SERVER_KEY environment variables.

Docker CLI

docker run --name hello -p 4062:4062/tcp -p 4062:4062/udp -v /path/to/certificates/:/certs icerpc/hello

Optional environment variables can be used to configure the server:

docker run \
--name hello \
-p 4062:4062/tcp -p 4062:4062/udp \
-v /path/to/certificates/:/certs \
-e LOG_LEVEL= \
-e SERVER_CERT= \
-e SERVER_KEY= \
icerpc/hello

Docker Compose

services:
hello:
image: icerpc/helloports:
- "4062:4062/tcp"
- "4062:4062/udp"environment:
- LOG_LEVEL= #optional
- SERVER_CERT= #optional
- SERVER_KEY= #optionalvolumes:
- /path/to/certificates/:/certs

Configuration

The server can be configured through several environment variables:

Environment VariableDescriptionDefault Value
LOG_LEVELThe log levelDebug
SERVER_CERTPath to the server certificate/certs/server_cert.pem
SERVER_KEYPath to the server private key/certs/server_key.pem

Certificates are required to run the server as the QUIC transport requires TLS.

Building with Docker Compose

This repository contains a Dockerfile that can be used to build the server as well as a compose.yaml file that can be used to build and run the server locally using Docker Compose.

The following commands must be run from the root directory of the repository.

# Start the server (builds the server if it does not exist)
docker compose up
# Rebuild the server
docker compose build

Once running, the server will be available at icerpc://localhost using the TCP and QUIC transports on the default port (4062).

Please refer to the Docker Compose documentation for more information on how to use Docker Compose.

About

A public IceRPC server - icerpc://hello.icerpc.dev

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

5 stars

Watchers

4 watching

Forks

Used by

Contributors

Languages