From c63fab572f91d2e4b0241b6ff1262871bbda7f61 Mon Sep 17 00:00:00 2001 From: Expand-sys Date: Tue, 13 Jul 2021 07:32:25 +1000 Subject: [PATCH 1/3] pushing files needed for docker --- config/config.json | 16 ++++++++++++++++ config/ssl.sh | 9 +++++++++ config/users.json | 7 +++++++ 3 files changed, 32 insertions(+) create mode 100644 config/config.json create mode 100644 config/ssl.sh create mode 100644 config/users.json diff --git a/config/config.json b/config/config.json new file mode 100644 index 0000000..686bec2 --- /dev/null +++ b/config/config.json @@ -0,0 +1,16 @@ +{ + "listeners": [ + { + "address": "0.0.0.0", + "port": 80, + "https": false + }, + { + "address": "0.0.0.0", + "port": 443, + "https": true, + "cert": "/CCash/config/cert.cert", + "key": "/CCash/config/key.key" + } + ] +} diff --git a/config/ssl.sh b/config/ssl.sh new file mode 100644 index 0000000..287bf12 --- /dev/null +++ b/config/ssl.sh @@ -0,0 +1,9 @@ +#!/bin/bash + + +openssl genrsa -out server.pass.key 2048 +openssl rsa -in server.pass.key -out /CCash/config/key.key +rm server.pass.key +openssl req -new -key /CCash/config/key.key -out server.csr \ + -subj "/C=US/ST=CCashland/L=NEW CCASH/O=CCash/OU=Devs/CN=localhost" +openssl x509 -req -days 365 -in server.csr -signkey /CCash/config/key.key -out /CCash/config/cert.cert diff --git a/config/users.json b/config/users.json new file mode 100644 index 0000000..828a47e --- /dev/null +++ b/config/users.json @@ -0,0 +1,7 @@ +{ + "": { + "balance": 0, + "log": null, + "password": 0 + } +} From 495403864fc72261bec5483ca4ab9922109ecac6 Mon Sep 17 00:00:00 2001 From: Expand-sys Date: Tue, 13 Jul 2021 07:50:18 +1000 Subject: [PATCH 2/3] pulling from github repo now so only docker file needed --- Dockerfile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index 9aabd40..3f2ff89 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,10 +1,10 @@ FROM alpine:3.11 -WORKDIR /CCash +WORKDIR / -RUN apk update && apk add cmake g++ make protobuf jsoncpp-dev openssl libressl-dev zlib-dev util-linux-dev libtool autoconf automake python3 +RUN apk update && apk add git cmake g++ make protobuf jsoncpp-dev openssl libressl-dev zlib-dev util-linux-dev libtool autoconf automake python3 -COPY . . +RUN git clone --recurse-submodules https://github.com/EntireTwix/CCash.git --branch Refractor RUN mkdir /CCash/build WORKDIR /CCash/build RUN cmake -DDROGON_CONFIG_LOC=\"\/CCash\/config\/config.json\" -DUSER_SAVE_LOC=\"\/CCash\/config\/users.json\" .. From 8217bb2360255b2c7573d180eaefa17c5c87ef70 Mon Sep 17 00:00:00 2001 From: Expand-sys Date: Tue, 13 Jul 2021 07:56:34 +1000 Subject: [PATCH 3/3] this done but needs twixie boi to merge --- Dockerfile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Dockerfile b/Dockerfile index 3f2ff89..8d8c984 100644 --- a/Dockerfile +++ b/Dockerfile @@ -5,6 +5,8 @@ WORKDIR / RUN apk update && apk add git cmake g++ make protobuf jsoncpp-dev openssl libressl-dev zlib-dev util-linux-dev libtool autoconf automake python3 RUN git clone --recurse-submodules https://github.com/EntireTwix/CCash.git --branch Refractor +WORKDIR /CCash/third_party/base64/ +RUN AVX2_CFLAGS=-mavx2 SSSE3_CFLAGS=-mssse3 SSE41_CFLAGS=-msse4.1 SSE42_CFLAGS=-msse4.2 AVX_CFLAGS=-mavx make lib/libbase64.o RUN mkdir /CCash/build WORKDIR /CCash/build RUN cmake -DDROGON_CONFIG_LOC=\"\/CCash\/config\/config.json\" -DUSER_SAVE_LOC=\"\/CCash\/config\/users.json\" ..