Skip to content

Commit 6c6dbc3

Browse files
authored
Optimize mofuw implementation (#304)
* remove unused files (mofuw) * homogenize implementation (inspiring from techempower)
1 parent 855afb7 commit 6c6dbc3

File tree

3 files changed

+18
-16
lines changed

3 files changed

+18
-16
lines changed

nim/mofuw/Dockerfile

Lines changed: 18 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,23 @@
1-
FROM nimlang/nim
1+
FROM gcc:latest
22

3-
WORKDIR /usr/src/app
3+
RUN apt update -yqq && \
4+
mkdir -p /nim && \
5+
cd /nim && \
6+
git clone -b devel https://github.com/nim-lang/Nim.git nim-devel && \
7+
cd nim-devel && \
8+
git clone --depth 1 https://github.com/nim-lang/csources.git && \
9+
cd csources && \
10+
sh build.sh && \
11+
cd ../ && \
12+
bin/nim c koch && \
13+
./koch boot -d:release && \
14+
./koch tools
415

5-
COPY server_nim_mofuw.nim server_nim_mofuw.nim.cfg server_nim_mofuw.nimble ./
16+
ENV PATH $PATH:/nim/nim-devel/bin:/root/.nimble/bin
617

7-
RUN nimble install -y
8-
RUN nim c -d:release -d:bufSize:512 server_nim_mofuw.nim
18+
COPY server_nim_mofuw.nim ./
19+
20+
RUN nimble install -y mofuw
21+
RUN nim c -d:release --threads:on -d:bufSize:512 server_nim_mofuw.nim
922

1023
CMD [ "./server_nim_mofuw" ]

nim/mofuw/server_nim_mofuw.nim.cfg

Lines changed: 0 additions & 1 deletion
This file was deleted.

nim/mofuw/server_nim_mofuw.nimble

Lines changed: 0 additions & 10 deletions
This file was deleted.

0 commit comments

Comments
 (0)