mirror of
https://gitea.invidious.io/iv-org/litespeed-quic.git
synced 2024-08-15 00:53:43 +00:00
Fix Docker build (#79)
This commit is contained in:
parent
c38e7df733
commit
2718741832
2 changed files with 23 additions and 16 deletions
23
Dockerfile
23
Dockerfile
|
@ -12,21 +12,18 @@ RUN add-apt-repository ppa:gophers/archive && \
|
||||||
RUN mkdir /src
|
RUN mkdir /src
|
||||||
WORKDIR /src
|
WORKDIR /src
|
||||||
|
|
||||||
|
RUN mkdir /src/lsquic
|
||||||
|
COPY ./ /src/lsquic/
|
||||||
|
|
||||||
RUN git clone https://boringssl.googlesource.com/boringssl && \
|
RUN git clone https://boringssl.googlesource.com/boringssl && \
|
||||||
cd boringssl && \
|
cd boringssl && \
|
||||||
git checkout chromium-stable && \
|
git checkout 32e59d2d3264e4e104b355ef73663b8b79ac4093 && \
|
||||||
|
patch -p1 -i /src/lsquic/patches/boringssl-meds.patch && \
|
||||||
cmake . && \
|
cmake . && \
|
||||||
make && \
|
|
||||||
BORINGSSL_SOURCE=$PWD && \
|
|
||||||
cd /usr/local/lib && \
|
|
||||||
cp $BORINGSSL_SOURCE/ssl/libssl.a . && \
|
|
||||||
cp $BORINGSSL_SOURCE/crypto/libcrypto.a .
|
|
||||||
|
|
||||||
RUN mkdir /src/lsquic-client
|
|
||||||
COPY ./ /src/lsquic-client/
|
|
||||||
RUN cd /src/lsquic-client && \
|
|
||||||
cmake -DBORINGSSL_INCLUDE=/src/boringssl/include \
|
|
||||||
-DBORINGSSL_LIB=/usr/local/lib . && \
|
|
||||||
make
|
make
|
||||||
|
|
||||||
RUN cd lsquic-client && make test && cp http_client /usr/bin/
|
RUN cd /src/lsquic && \
|
||||||
|
cmake -DBORINGSSL_DIR=/src/boringssl . && \
|
||||||
|
make
|
||||||
|
|
||||||
|
RUN cd lsquic && make test && cp http_client /usr/bin/ && cp http_server /usr/bin
|
||||||
|
|
16
README.md
16
README.md
|
@ -112,14 +112,24 @@ make test
|
||||||
|
|
||||||
Building with Docker
|
Building with Docker
|
||||||
---------
|
---------
|
||||||
The library and http_client example can be built with Docker.
|
The library and the example client and server can be built with Docker.
|
||||||
|
|
||||||
|
Initialize Git submodules:
|
||||||
|
```
|
||||||
|
cd lsquic
|
||||||
|
git submodule init
|
||||||
|
git submodule update
|
||||||
|
```
|
||||||
|
|
||||||
|
Build the Docker image:
|
||||||
```
|
```
|
||||||
docker build -t lsquic .
|
docker build -t lsquic .
|
||||||
```
|
```
|
||||||
|
|
||||||
Then you can use the http_client example from the command line.
|
Then you can use the examples from the command line. For example:
|
||||||
```
|
```
|
||||||
docker run -it --rm lsquic http_client -H www.google.com -s 74.125.22.106:443 -p /
|
sudo docker run -it --rm lsquic http_client -s www.google.com -p / -o version=Q046
|
||||||
|
sudo docker run -p 12345:12345/udp -v /path/to/certs:/mnt/certs -it --rm lsquic http_server -c www.example.com,/mnt/certs/chain,/mnt/certs/key
|
||||||
```
|
```
|
||||||
|
|
||||||
Platforms
|
Platforms
|
||||||
|
|
Loading…
Reference in a new issue