-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
65 lines (59 loc) · 2.5 KB
/
Dockerfile
File metadata and controls
65 lines (59 loc) · 2.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
FROM ubuntu:noble
# FROM debian:bookworm
# FROM fedora:42
RUN set -e && \
DISTRO=$(grep "^ID=" /etc/os-release | cut -d= -f2 | tr -d '"' | tr '[:upper:]' '[:lower:]') && \
echo "Installing dependencies for distribution: $DISTRO" && \
case "$DISTRO" in \
debian|ubuntu) \
apt-get update && \
apt-get install -y wget curl ca-certificates jq gnupg lsb-release git vim nano make && \
apt-get clean; \
;; \
fedora) \
dnf -y update && \
dnf install -y wget curl ca-certificates jq redhat-lsb-core git vim nano make && \
dnf clean all; \
;; \
*) \
echo "Unsupported distribution for package installation: $DISTRO"; \
exit 1; \
;; \
esac
RUN set -e && \
DISTRO=$(grep "^ID=" /etc/os-release | cut -d= -f2 | tr -d '"' | tr '[:upper:]' '[:lower:]') && \
echo "Detecting distribution for deceptgold installation: $DISTRO" && \
case "$DISTRO" in \
debian) \
ASSET=$(curl -s https://api.github.com/repos/New-Resolve/deceptgold/releases/latest | \
jq -r '.assets[] | select(.name | endswith("debian-bookworm_amd64.deb")) | .browser_download_url'); \
PACKAGE="deceptgold.deb"; \
wget "$ASSET" -O "$PACKAGE"; \
apt-get update && apt-get install -y ./"$PACKAGE"; \
;; \
ubuntu) \
ASSET=$(curl -s https://api.github.com/repos/New-Resolve/deceptgold/releases/latest | \
jq -r '.assets[] | select(.name | endswith("ubuntu-noble_amd64.deb")) | .browser_download_url'); \
PACKAGE="deceptgold.deb"; \
wget "$ASSET" -O "$PACKAGE"; \
apt-get update && apt-get install -y ./"$PACKAGE"; \
;; \
fedora) \
ASSET=$(curl -s https://api.github.com/repos/New-Resolve/deceptgold/releases/latest | \
jq -r '.assets[] | select(.name | endswith(".x86_64.rpm")) | .browser_download_url'); \
PACKAGE="deceptgold.rpm"; \
wget "$ASSET" -O "$PACKAGE"; \
dnf install -y ./"$PACKAGE"; \
;; \
*) \
echo "Unsupported distribution for deceptgold: $DISTRO"; \
exit 1; \
;; \
esac && rm -f "$PACKAGE"
EXPOSE 2121 2222 8090
# Enable debug mode to show full tracebacks
# ENV DECEPTGOLD_DEBUG=1
# Default command to start deceptgold in development mode
# Developers can override with `docker run -it <image> bash` for interactive debugging
# CMD ["deceptgold", "service", "start", "daemon=false", "force-no-wallet=true"]
CMD ["deceptgold", "--help"]