Compare commits

...

2 Commits

Author SHA1 Message Date
c3c7d22006 Actually Fix CI
All checks were successful
minecraft-pi-reborn/pipeline/head This commit looks good
2022-07-15 20:09:51 -04:00
3abbb0cb16 Improve Server Dockerfile 2022-07-15 19:54:58 -04:00
3 changed files with 6 additions and 3 deletions

View File

@ -3,7 +3,7 @@ FROM debian:bullseye-slim
# Install
RUN \
apt-get update && \
apt-get install -y tini sed patchelf qemu-user && \
apt-get install -y tini qemu-user && \
apt-get --fix-broken install -y && \
rm -rf /var/lib/apt/lists/*

View File

@ -142,7 +142,7 @@ static void set_env_if_unset(const char *env_name, std::function<std::string()>
#define LIST_DIALOG_SIZE "400"
int main(int argc, char *argv[]) {
// Don't Run As Root
if (getuid() == 0 || geteuid() == 0) {
if (getenv("_MCPI_SKIP_ROOT_CHECK") == NULL && (getuid() == 0 || geteuid() == 0)) {
ERR("Don't Run As Root");
}

View File

@ -23,9 +23,12 @@ cd ../../
./scripts/setup.sh client "${ARCH}" -DMCPI_HEADLESS_MODE=ON
./scripts/build.sh client "${ARCH}"
# Add minecraft-pi-reborn-server To PATH
# Add minecraft-pi-reborn-client To PATH
export PATH="$(pwd)/out/client-$(dpkg-architecture -qDEB_BUILD_ARCH)/usr/bin:${PATH}"
# Skip Root Check
export _MCPI_SKIP_ROOT_CHECK=1
# Run Benchmark
export HOME="$(pwd)/build/test"
minecraft-pi-reborn-client --default --benchmark