diff --git a/TODO b/TODO index e3dfecee..1ea26d3f 100644 --- a/TODO +++ b/TODO @@ -1,8 +1,6 @@ A fazer - Checar se tem como atualizar microcode via addon/modules/whatever... - Estudar acrescentar modo simples e avançado do menu - - Adicionar mais bnários para o addon dbgutils (nano, trace, etc) - - Retirar o ttyd da memória quando o root do dsm dar boot Concluidos: - Generalizar código dos addons @@ -31,3 +29,5 @@ Concluidos: - Mudar synoinfo para ler do modelo e preencher no user_config, para usuário poder deletar entradas do modelo - Validar netif_num e macX - Descobrir como é o serial do DS2422+ + - Retirar o ttyd da memória quando o root do dsm dar boot + - Adicionar mais binários para o addon dbgutils (nano, strace, etc) diff --git a/docker/Dockerfile.template b/docker/Dockerfile.template index e97e0ec2..b03e565f 100644 --- a/docker/Dockerfile.template +++ b/docker/Dockerfile.template @@ -24,15 +24,18 @@ ENV SHELL=/bin/bash \ RUN apt update --yes && \ apt install --yes --no-install-recommends --no-install-suggests \ - ca-certificates nano curl bc kmod git gettext texinfo autopoint \ + ca-certificates nano curl bc kmod git gettext texinfo autopoint gawk sudo \ build-essential make ncurses-dev libssl-dev autogen automake pkg-config libtool xsltproc gperf && \ apt-get clean && \ - rm -rf /var/lib/apt/lists/* + rm -rf /var/lib/apt/lists/* && \ + useradd --home-dir /input --no-create-home --shell /bin/bash --uid 1000 arpl && \ + echo "arpl ALL=(ALL) NOPASSWD:ALL" > /etc/sudoers.d/arpl COPY --from=stage /opt /opt COPY files/ / WORKDIR /input VOLUME /input /output +USER arpl ENTRYPOINT ["/opt/do.sh"] diff --git a/docker/files/opt/do.sh b/docker/files/opt/do.sh index 8e8feef7..92d02ef5 100755 --- a/docker/files/opt/do.sh +++ b/docker/files/opt/do.sh @@ -15,6 +15,9 @@ function export-vars() { export LDFLAGS="-I/opt/${1}/lib" export LD_LIBRARY_PATH="/opt/${1}/lib" export ARCH=x86_64 + export PATH="/opt/${1}/bin:${PATH}" + export CC="x86_64-pc-linux-gnu-gcc" + export LD="x86_64-pc-linux-gnu-ld" } ############################################################################### diff --git a/files/board/arpl/p3/addons/dbgutils/all.tgz b/files/board/arpl/p3/addons/dbgutils/all.tgz index 80cdb881..afd49954 100644 Binary files a/files/board/arpl/p3/addons/dbgutils/all.tgz and b/files/board/arpl/p3/addons/dbgutils/all.tgz differ