mirror of
				https://github.com/yggdrasil-network/yggdrasil-go.git
				synced 2025-11-04 03:05:07 +03:00 
			
		
		
		
	# Summary This PR addresses failures to run Yggdrasil on ARM systems. The root cause was the lack of ARM artifacts/images, which led to exec format error and similar issues. ## What’s added: - ```Dockerfile.multiarch``` — multi-stage Go build that correctly propagates GOOS/GOARCH for linux/amd64, linux/arm64, linux/armhf and linux/armel platform. - ```entrypoint.sh``` - Introduced ENV **ALLOW_IPV6_FORWARDING**. When set to a truthy value (e.g., true), the entrypoint executes: ```sysctl -w net.ipv6.conf.all.forwarding=1```. - GitHub Action for multi-arch builds and publishing to GHCR — triggered via ```workflow_dispatch```, push to ```master``` and release via tags (with docker semantic tags e.g. v0.5.12 → 0.5.12, 0.5, 0). Example published images: [https://github.com/Forne/yggdrasil-go/pkgs/container/yggdrasil-go](https://github.com/Forne/yggdrasil-go/pkgs/container/yggdrasil-go) ## Testing ✅ Ubuntu (24.04, amd64) — image runs correctly. ✅ macOS (Apple Silicon, arm64) — image runs correctly. ✅ MikroTik RouterOS (arm64) — image runs under the RouterOS container package.
		
			
				
	
	
		
			18 lines
		
	
	
	
		
			392 B
		
	
	
	
		
			Bash
		
	
	
		
			Executable file
		
	
	
	
	
			
		
		
	
	
			18 lines
		
	
	
	
		
			392 B
		
	
	
	
		
			Bash
		
	
	
		
			Executable file
		
	
	
	
	
#!/usr/bin/env sh
 | 
						|
 | 
						|
set -e
 | 
						|
 | 
						|
CONF_DIR="/etc/yggdrasil-network"
 | 
						|
 | 
						|
if [ ! -f "$CONF_DIR/config.conf" ]; then
 | 
						|
  echo "generate $CONF_DIR/config.conf"
 | 
						|
  yggdrasil --genconf > "$CONF_DIR/config.conf"
 | 
						|
fi
 | 
						|
 | 
						|
if [ -n "$ALLOW_IPV6_FORWARDING" ]; then
 | 
						|
  echo "set sysctl -w net.ipv6.conf.all.forwarding=1"
 | 
						|
  sysctl -w net.ipv6.conf.all.forwarding=1
 | 
						|
fi
 | 
						|
 | 
						|
yggdrasil --useconf < "$CONF_DIR/config.conf"
 | 
						|
exit $?
 |