electrs dockerfile
All checks were successful
Build Docker Image / build (push) Successful in 2m40s

This commit is contained in:
2025-12-02 22:35:26 -06:00
parent 3db532de6f
commit cf8ccf1137
4 changed files with 19 additions and 4 deletions

2
.gitignore vendored
View File

@@ -1,6 +1,6 @@
.git/ .git/
__pycache__/ __pycache__/
.venv/ .venv/
test/ dev/
.devcontainer/ .devcontainer/

View File

@@ -3,6 +3,9 @@ import logging
# Setup logging # Setup logging
def setup_log(): def setup_log():
"""
Setup logging
"""
loglevel = 10 if os.getenv("APKG_TARGET") == "debug" else 20 loglevel = 10 if os.getenv("APKG_TARGET") == "debug" else 20
logging.basicConfig( logging.basicConfig(

View File

@@ -28,7 +28,9 @@ class Autopkg:
# Logging Setup # Logging Setup
setup_log() setup_log()
logging.info("Running autopkg (c) 2025 phantom <phantom@shadeouts.net> https://shadeouts.net/") logging.info(
"Running autopkg (c) 2025 phantom <phantom@shadeouts.net> https://shadeouts.net/"
)
# Environment Setup # Environment Setup
target = os.getenv("APKG_TARGET") target = os.getenv("APKG_TARGET")
@@ -40,7 +42,7 @@ class Autopkg:
case "test" | "debug": case "test" | "debug":
logging.warning("Running autopkg in testing mode!") logging.warning("Running autopkg in testing mode!")
self.datafile = os.getenv("APKG_RUNTIME_DIR") + "/test/data.ini" self.datafile = os.getenv("APKG_RUNTIME_DIR") + "/dev/data.ini"
if os.path.exists(self.datafile): os.remove(self.datafile) if os.path.exists(self.datafile): os.remove(self.datafile)
case _: case _:

View File

@@ -1 +1,11 @@
FROM debian:bookworm as base FROM debian:bookworm
RUN apt-get update && apt-get install git cargo build-essential libclang-dev=9.10.0-1
WORKDIR /build
# Build
RUN git clone https://github.com/romanz/electrs .
RUN ROCKSDB_INCLUDE_DIR=/usr/include ROCKSDB_LIB_DIR=/usr/lib cargo build --locked --release