From 40a15230ca99a07c98b7e0c1b09e5cb07f2fe5ba Mon Sep 17 00:00:00 2001 From: chabisik Date: Fri, 11 Dec 2020 12:44:52 +0100 Subject: [PATCH] mise a jour --- Dockerfiles/device/Dockerfile | 21 +++++++++++++++ Dockerfiles/explanations.txt | 45 +++++++++++++++++++++++++++++++++ Dockerfiles/gatewayF/Dockerfile | 23 +++++++++++++++++ Dockerfiles/gatewayI/Dockerfile | 21 +++++++++++++++ 4 files changed, 110 insertions(+) create mode 100644 Dockerfiles/device/Dockerfile create mode 100644 Dockerfiles/explanations.txt create mode 100644 Dockerfiles/gatewayF/Dockerfile create mode 100644 Dockerfiles/gatewayI/Dockerfile diff --git a/Dockerfiles/device/Dockerfile b/Dockerfiles/device/Dockerfile new file mode 100644 index 0000000..0536fae --- /dev/null +++ b/Dockerfiles/device/Dockerfile @@ -0,0 +1,21 @@ +# Choosing the image to use +FROM node:alpine + +# Installing required libraries +RUN apk add npm && \ + mkdir device && \ + cd device && \ + npm install express && \ + npm install yargs && \ + npm install systeminformation && \ + wget http://homepages.laas.fr/smedjiah/tmp/device.js + +# set entry point for emulator gatekeeper (needed for compatibility with vim-emu datacenters) +#ENV VIM_EMU_CMD "node /device/device.js --local_ip "127.0.0.1" --local_port 9001 --local_name "dev1" --remote_ip "127.0.0.1" --remote_port 8282 --remote_name "gwf1" --send_period 3000" #uncomment when on ContainerNet datacenter +#ENV VIM_EMU_CMD "TODO at startup" +#ENV VIM_EMU_CMD_STOP "TODO at shutdown" + +# CMD should always point to /bin/bash to not block the emulator (sh for node:alpine) +CMD node /device/device.js --local_ip "127.0.0.1" --local_port 9001 --local_name "dev1" --remote_ip "127.0.0.1" --remote_port 8282 --remote_name "gwf1" --send_period 3000 #comment when on ContainerNet datacenter +#CMD /bin/sh #uncomment when on ContainerNet datacenter + diff --git a/Dockerfiles/explanations.txt b/Dockerfiles/explanations.txt new file mode 100644 index 0000000..13ce461 --- /dev/null +++ b/Dockerfiles/explanations.txt @@ -0,0 +1,45 @@ +Test Architecture + +********************** +* CONTAINER * +* IP = x.x.x.x * +* * +* ++++++++++++++++++ * +* + SERVER (srv) + * +* + IP = 127.0.0.1 + * +* + PORT = 8080 + * +* ++++++++++++++++++ * +********************** + || +********************** +* CONTAINER * +* IP = x.x.x.x * +* * +* ++++++++++++++++++ * +* + GATWEWAY (gwi) + * +* + IP = 127.0.0.1 + * +* + PORT = 8181 + * +* ++++++++++++++++++ * +********************** + || +********************** +* CONTAINER * +* IP = x.x.x.x * +* * +* ++++++++++++++++++ * +* + GATEWAY (gwf1) + * +* + IP = 127.0.0.1 + * +* + PORT = 8282 + * +* ++++++++++++++++++ * +********************** + || +********************** +* CONTAINER * +* IP = x.x.x.x * +* * +* ++++++++++++++++++ * +* + DEVICE (dev1) + * +* + IP = 127.0.0.1 + * +* + PORT = 9001 + * +* ++++++++++++++++++ * +********************** diff --git a/Dockerfiles/gatewayF/Dockerfile b/Dockerfiles/gatewayF/Dockerfile new file mode 100644 index 0000000..c70ddcc --- /dev/null +++ b/Dockerfiles/gatewayF/Dockerfile @@ -0,0 +1,23 @@ +# Choosing the image to use +FROM node:alpine + +# Installing required libraries +RUN apk add npm && \ + mkdir gateway && \ + cd gateway && \ + npm install express && \ + npm install yargs && \ + npm install systeminformation && \ + wget http://homepages.laas.fr/smedjiah/tmp/gateway.js + +# set entry point for emulator gatekeeper (needed for compatibility with vim-emu datacenters) +#ENV VIM_EMU_CMD "node /gateway/gateway.js --local_ip "127.0.0.1" --local_port 8282 --local_name "gwf1" --remote_ip "127.0.0.1" --remote_port 8181 --remote_name "gwi" + #uncomment when on ContainerNet datacenter +#ENV VIM_EMU_CMD "TODO at startup" +#ENV VIM_EMU_CMD_STOP "TODO at shutdown" + +# CMD should always point to /bin/bash to not block the emulator (sh for node:alpine) +CMD node /gateway/gateway.js --local_ip "127.0.0.1" --local_port 8282 --local_name "gwf1" --remote_ip "127.0.0.1" --remote_port 8181 --remote_name "gwi" + #comment when on ContainerNet datacenter +#CMD /bin/sh #uncomment when on ContainerNet datacenter + diff --git a/Dockerfiles/gatewayI/Dockerfile b/Dockerfiles/gatewayI/Dockerfile new file mode 100644 index 0000000..518d4e0 --- /dev/null +++ b/Dockerfiles/gatewayI/Dockerfile @@ -0,0 +1,21 @@ +# Choosing the image to use +FROM node:alpine + +# Installing required libraries +RUN apk add npm && \ + mkdir gateway && \ + cd gateway && \ + npm install express && \ + npm install yargs && \ + npm install systeminformation && \ + wget http://homepages.laas.fr/smedjiah/tmp/gateway.js + +# set entry point for emulator gatekeeper (needed for compatibility with vim-emu datacenters) +#ENV VIM_EMU_CMD "node /gateway/gateway.js --local_ip "127.0.0.1" --local_port 8181 --local_name "gwi" --remote_ip "127.0.0.1" --remote_port 8080 --remote_name "srv" #uncomment when on ContainerNet datacenter +#ENV VIM_EMU_CMD "TODO at startup" +#ENV VIM_EMU_CMD_STOP "TODO at shutdown" + +# CMD should always point to /bin/bash to not block the emulator (sh for node:alpine) +CMD node /gateway/gateway.js --local_ip "127.0.0.1" --local_port 8181 --local_name "gwi" --remote_ip "127.0.0.1" --remote_port 8080 --remote_name "srv" #comment when on ContainerNet datacenter +#CMD /bin/sh #uncomment when on ContainerNet datacenter +