Skip to content

Commit 1fc1e37

Browse files
committed
feature: docker: io: apt-get upgrade
1 parent 582b742 commit 1fc1e37

4 files changed

Lines changed: 27 additions & 34 deletions

File tree

docker/Dockerfile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,10 @@
11
FROM node
2+
23
LABEL maintainer="Coderaiser"
34
LABEL org.opencontainers.image.source="https://github.com/coderaiser/cloudcmd"
45

56
RUN mkdir -p /usr/src/cloudcmd
7+
68
WORKDIR /usr/src/cloudcmd
79

810
COPY package.json /usr/src/cloudcmd/

docker/Dockerfile.alpine

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,10 @@
11
FROM node:alpine
2+
23
LABEL maintainer="Coderaiser"
34
LABEL org.opencontainers.image.source="https://github.com/coderaiser/cloudcmd"
45

56
RUN mkdir -p /usr/src/cloudcmd
7+
68
WORKDIR /usr/src/cloudcmd
79

810
COPY package.json /usr/src/cloudcmd/
@@ -21,6 +23,7 @@ RUN apk update && \
2123
COPY . /usr/src/cloudcmd
2224

2325
WORKDIR /
26+
2427
ENV cloudcmd_terminal=true
2528
ENV cloudcmd_terminal_path=gritty
2629
ENV cloudcmd_open=false
@@ -29,4 +32,3 @@ ENV cloudcmd_vim=true
2932
EXPOSE 8000
3033

3134
ENTRYPOINT ["/usr/src/cloudcmd/bin/cloudcmd.js"]
32-

docker/Dockerfile.io

Lines changed: 21 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,33 @@
11
FROM node
2+
23
LABEL maintainer="Coderaiser"
34
LABEL org.opencontainers.image.source="https://github.com/coderaiser/cloudcmd"
45

56
RUN mkdir -p /usr/src/cloudcmd
7+
68
WORKDIR /usr/src/cloudcmd
79

810
COPY package.json /usr/src/cloudcmd/
911

10-
ENV DEBIAN_FRONTEND=noninteractive
11-
ENV PATH=/usr/local/src/cargo/bin:$PATH
12+
ENV DEBIAN_FRONTEND=noninteractive \
13+
PATH=/usr/local/src/cargo/bin:$PATH
1214

1315
ARG GO_VERSION=1.21.2
1416

15-
RUN apt-get update && apt-get upgrade -y && apt-get autoremove && \
16-
apt-get install -y less ffmpeg net-tools netcat-openbsd mc iputils-ping vim neovim bat fzf \
17-
locales sudo command-not-found && \
17+
RUN apt-get update && \
18+
apt-get upgrade -y && \
19+
apt-get autoremove && \
20+
apt-get install -y less ffmpeg net-tools netcat-openbsd mc iputils-ping vim neovim bat fzf locales sudo command-not-found && \
1821
echo "> Update command-not-found database. Run 'sudo apt update' to populate it." && \
1922
apt-get update && \
20-
apt-get autoremove && apt-get clean && \
23+
apt-get autoremove && \
24+
apt-get clean && \
2125
rm -rf /var/lib/apt/lists/* && \
22-
echo "> install nix" && \
23-
useradd -m -s /bin/bash nixuser && \
24-
echo "nixuser ALL=(ALL) NOPASSWD:ALL" > /etc/sudoers.d/nixuser && \
25-
chmod 0440 /etc/sudoers.d/nixuser && \
26-
su - nixuser -c "curl -L https://nixos.org/nix/install | sh -s -- --no-daemon --no-sendbox" && \
27-
mv /home/nixuser/.nix-profile /usr/local/src/nix-profile && \
28-
mv /home/nixuser/.nix-defexpr /usr/local/src/nix-defexpr && \
29-
rm -rf /etc/sudoers.d/nixuser && \
30-
userdel -r nixuser && \
3126
echo "> install nvm" && \
3227
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.4/install.sh | bash && \
3328
mv ~/.nvm /usr/local/src/nvm && \
3429
echo "> install npm globals" && \
35-
npm i wisdom nupdate version-io redrun superc8 \
36-
supertape madrun redlint putout renamify-cli runny redfork -g && \
30+
npm i wisdom nupdate version-io redrun superc8 supertape madrun redlint putout renamify-cli runny redfork -g && \
3731
echo "> install bun" && \
3832
curl -fsSL https://bun.sh/install | bash && \
3933
mv ~/.bun /usr/local/src/bun && \
@@ -83,22 +77,16 @@ COPY . /usr/src/cloudcmd
8377
8478
WORKDIR /
8579
86-
ENV cloudcmd_terminal=true
87-
ENV cloudcmd_terminal_path=gritty
88-
ENV cloudcmd_open=false
89-
90-
ENV PATH=node_modules/.bin:$PATH
91-
ENV PATH=/usr/local/src/nix/profile/bin:$PATH
92-
ENV NIX_PATH=/usr/local/src/nix/defexpr/channels
93-
94-
ENV BUN_INSTALL_CACHE_DIR=/tmp/bun-cache
95-
ENV DENO_DIR=/tmp/deno-cache
96-
97-
ENV LANG=en_US.UTF-8
98-
ENV LANGUAGE=en_US:en
99-
ENV LC_ALL=en_US.UTF-8
100-
101-
ENV TERM=xterm-256color
80+
ENV cloudcmd_terminal=true \
81+
cloudcmd_terminal_path=gritty \
82+
cloudcmd_open=false \
83+
PATH=node_modules/.bin:$PATH \
84+
BUN_INSTALL_CACHE_DIR=/tmp/bun-cache \
85+
DENO_DIR=/tmp/deno-cache \
86+
LANG=en_US.UTF-8 \
87+
LANGUAGE=en_US:en \
88+
LC_ALL=en_US.UTF-8 \
89+
TERM=xterm-256color
10290
10391
EXPOSE 8000
10492

docker/Dockerfile.slim

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
FROM node:slim AS build
22

33
RUN mkdir -p /usr/src/cloudcmd/
4+
45
WORKDIR /usr/src/cloudcmd
56

67
COPY package.json /usr/src/cloudcmd/

0 commit comments

Comments
 (0)