Factorio ARM64

Games
Report Issue

The vanilla Factorio server. https://www.factorio.com/

Contributors:
Docker Images (1)
Name Image
Box64 ghcr.io/ptero-eggs/yolks:box64
Startup Command
if [ ! -f "./saves/{{SAVE_NAME}}.zip" ]; then box64 ./bin/x64/factorio --create ./saves/{{SAVE_NAME}}.zip --map-gen-settings data/map-gen-settings.json --map-settings data/map-settings.json; fi;
box64 ./bin/x64/factorio --port {{SERVER_PORT}} --server-settings data/server-settings.json --start-server saves/{{SAVE_NAME}}.zip
Variables (16)

Factorio Version

Which version of Factorio to install and use.

Environment:
FACTORIO_VERSION
Default:
latest
User Viewable:
User Editable:
Rules:
required|string|between:3,12

Maximum Slots

Total number of slots to allow on the server.

Environment:
MAX_SLOTS
Default:
20
User Viewable:
User Editable:
Rules:
required|numeric|digits_between:1,3

Save Name

The save name for the server.

Environment:
SAVE_NAME
Default:
gamesave
User Viewable:
User Editable:
Rules:
alpha_dash|between:1,100

Server Token

Your factorio.com token, it is required for your server to be visible in the public server list.

Environment:
SERVER_TOKEN
Default:
undefined
User Viewable:
User Editable:
Rules:
alpha_num|max:100

Server Name

Name of the game as it will appear in the game listing

Environment:
SERVER_NAME
Default:
Factorio Server
User Viewable:
User Editable:
Rules:
required|string|max:100

Server Description

Description of the game that will appear in the listing.

Environment:
SERVER_DESC
Default:
Description
User Viewable:
User Editable:
Rules:
required|string|max:200

Server Username

Username used for the server

Environment:
SERVER_USERNAME
Default:
unnamed
User Viewable:
User Editable:
Rules:
required|string|max:40

Auto Save Interval

Time between auto saves specified in minutes

Environment:
SAVE_INTERVAL
Default:
10
User Viewable:
User Editable:
Rules:
required|numeric|digits_between:1,3

Auto Save Slots

The number of auto saves to keep.

Environment:
SAVE_SLOTS
Default:
5
User Viewable:
User Editable:
Rules:
required|numeric|digits_between:1,3

AFK Kick

Time specified in minutes to kick AFK players. 0 is off

Environment:
AFK_KICK
Default:
0
User Viewable:
User Editable:
Rules:
required|numeric|digits_between:1,3

BOX64_DYNAREC_SAFEFLAGS

Environment:
BOX64_DYNAREC_SAFEFLAGS
Default:
0
User Viewable:
User Editable:
Rules:
required|numeric|in:0

BOX64_DYNAREC_BIGBLOCK

Environment:
BOX64_DYNAREC_BIGBLOCK
Default:
2
User Viewable:
User Editable:
Rules:
required|numeric|in:2

BOX64_DYNAREC_FORWARD

Environment:
BOX64_DYNAREC_FORWARD
Default:
1024
User Viewable:
User Editable:
Rules:
required|numeric|in:1024

BOX64_DYNAREC_CALLRET

Environment:
BOX64_DYNAREC_CALLRET
Default:
1
User Viewable:
User Editable:
Rules:
required|numeric|in:1

BOX64_DYNAREC_FASTROUND

Environment:
BOX64_DYNAREC_FASTROUND
Default:
0
User Viewable:
User Editable:
Rules:
required|numeric|in:0

BOX64_DYNAREC_ALIGNED_ATOMICS

Environment:
BOX64_DYNAREC_ALIGNED_ATOMICS
Default:
1
User Viewable:
User Editable:
Rules:
required|numeric|in:1
Installation Script
Container: ghcr.io/ptero-eggs/installers:debian
Entrypoint: bash
#!/bin/bash
# Factorio Installation Script
#
# Server Files: /mnt/server
apt update 
apt install -y curl tar xz-utils jq

VERSION_JSON=$(curl -sSL https://factorio.com/api/latest-releases)

latest_stable=$(echo $VERSION_JSON | jq -r '.stable.headless')
latest_experimental=$(echo $VERSION_JSON | jq -r '.experimental.headless')

if [ -z "${FACTORIO_VERSION}" ] || [ "${FACTORIO_VERSION}" == "latest" ]; then
  DL_VERSION=$latest_stable
elif [ "${FACTORIO_VERSION}" == "experimental" ]; then
  DL_VERSION=$latest_experimental
else
  DL_VERSION=${FACTORIO_VERSION}
fi

mkdir -p /mnt/server
cd /mnt/server

echo -e "\n running 'curl -sL https://www.factorio.com/get-download/${DL_VERSION}/headless/linux64 -o factorio-${DL_VERSION}' \n"

curl -sL https://www.factorio.com/get-download/${DL_VERSION}/headless/linux64 -o factorio-${DL_VERSION}

tar -xf factorio-${DL_VERSION} --strip-components=1 -C /mnt/server

rm factorio-${DL_VERSION}

if [ -e data/map-gen-settings.json ]; then
    echo "map-gen exists"
else
    echo "copying map-gen default settings"
    mv data/map-gen-settings.example.json data/map-gen-settings.json
fi

if [ -e data/server-settings.json ]; then
    echo "server settings exists"
else
    echo "copying server default settings"
    mv data/server-settings.example.json data/server-settings.json
fi

if [ -e map-settings.json ]; then
    echo "map settings exists"
else
    echo "copying map default settings"
    mv data/map-settings.example.json data/map-settings.json
fi


## install end
echo "-----------------------------------------"
echo "Installation completed..."
echo "-----------------------------------------"