Skip to main content

Ygégé CI/CD Pipeline Guide

Quick Start: This document explains how Ygégé is automatically built, tested, and distributed. Use this as a reference for troubleshooting build issues or understanding the release process.

📋 Table of Contents


What Gets Built Automatically

Every time code is pushed to GitHub, our automated system builds Ygégé for multiple platforms:

📦 Binary Downloads (16 variants)

PlatformArchitecturesTypes
Linux (glibc)x86_64, i686, aarch64, armv7Normal + UPX compressed
Windowsx86_64, i686Normal + UPX compressed
macOSIntel (x86_64), Apple Silicon (aarch64)Normal + UPX compressed

What's UPX? Compressed versions are 50-70% smaller but take slightly longer to start. Use normal version if unsure.

🐳 Docker Images (2 platforms)

ArchitectureDevices
linux/amd64Most PCs, servers, cloud instances
linux/arm64Raspberry Pi 4+, Apple M1/M2/M3, AWS Graviton

How to Get Ygégé

# Latest stable version
docker pull uwucode/ygege:latest

# Development version (latest features, may be unstable)
docker pull uwucode/ygege:develop

# Specific version
docker pull uwucode/ygege:0.4.2

Alternative registry (GitHub):

docker pull ghcr.io/uwudev/ygege:latest

Run with Docker:

docker run -d \
-p 8080:8080 \
-v ./sessions:/app/sessions \
uwucode/ygege:latest

Option 2: Download Binaries

💾 Download from GitHub Actions

  1. Go to GitHub Actions
  2. Click on the latest successful workflow run
  3. Scroll to "Artifacts" section
  4. Download the file matching your system:
    • Linux (most systems): ygege-linux-gnu-x86_64.zip
    • Linux (ARM/Raspberry Pi): ygege-linux-gnu-aarch64.zip or ygege-linux-gnu-armv7.zip
    • Windows: ygege-windows-x86_64.zip
    • macOS (Intel): ygege-macos-x86_64.zip
    • macOS (Apple Silicon): ygege-macos-aarch64.zip

Want smaller files? Look for -upx versions (e.g., ygege-linux-gnu-x86_64-upx.zip)

Note: Artifacts are kept for 7 days. For permanent releases, use Docker images or wait for a tagged release.


Branch Strategy

Understanding which version you're using:

BranchPurposeWhen to useDocker Tag
masterStable releasesProduction uselatest, stable, 0.4.2
developLatest developmentTesting new featuresdevelop

Which one to use?

  • 🟢 master: For production servers (most stable)
  • 🔴 develop: For developers and early testers (may contain bugs)

Version Information

Check Your Version

Every Ygégé binary includes build information:

# Show version details
./ygege --version

Output:

Ygégé v0.4.2
Commit: a1b2c3d4e5f6
Build Date: 2025-11-11T10:30:00Z
Branch: develop

What this tells you:

  • Version: The release number
  • Commit: Exact code snapshot (useful for bug reports)
  • Build Date: When this binary was compiled
  • Branch: Which version branch you're using

Version in Logs

When you start Ygégé, it automatically logs version info:

INFO Ygégé v0.4.2 (commit: a1b2c3d, branch: develop, built: 2025-11-11T10:30:00Z)
INFO Logged in to YGG with username: youruser

Troubleshooting

❓ "I can't find the binary for my system"

Solution: Check the Artifacts section in GitHub Actions. We build for:

  • Linux: x86_64 (most PCs), i686 (32-bit), aarch64 (64-bit ARM), armv7 (32-bit ARM)
  • Windows: x86_64 (64-bit), i686 (32-bit)
  • macOS: x86_64 (Intel), aarch64 (Apple Silicon)

Not listed? Open an issue requesting your platform.

❓ "Docker pull fails or image not found"

Check:

  1. Spelling: uwucode/ygege (not uwudev)
  2. Tag exists: develop, latest, stable, or version number
  3. Try alternative registry: ghcr.io/uwudev/ygege:latest

Example error:

Error: manifest for uwucode/ygege:wrong-tag not found

Fix: Use valid tag like develop or latest

❓ "Binary won't run / Permission denied"

Linux/macOS:

chmod +x ygege
./ygege

Windows: Right-click → Properties → Unblock → Apply

❓ "UPX version crashes on startup"

Solution: Use the normal (non-UPX) version. Some antivirus software flags compressed executables.

❓ "How do I report a build issue?"

When reporting issues, include:

  1. Your system: OS, architecture (run uname -m on Linux/macOS)
  2. Version info: Output of ./ygege --version
  3. How you got it: Docker tag or artifact name
  4. Error message: Full error output

Template:

System: Ubuntu 22.04 x86_64
Version: Ygégé v0.4.2 (commit: a1b2c3d, branch: develop)
Source: Docker uwucode/ygege:develop
Error: [paste error here]

❓ "Artifacts expired (404 error)"

Artifacts are kept for 7 days. Options:

  • Use Docker images (permanent)
  • Build from source
  • Wait for next commit to trigger new builds

For Contributors

Setting Up CI/CD

Required GitHub Secrets:

Go to: SettingsSecrets and variablesActionsNew repository secret

Secret NameDescriptionHow to Get
DOCKERHUB_USERNAMEYour Docker Hub usernameYour Docker Hub account name
DOCKERHUB_TOKENDocker Hub access tokenCreate token

Note: GITHUB_TOKEN is automatic, no setup needed.

When does CI run?

EventWhat happens
Push to develop/masterFull build + Docker publish + artifacts
Pull RequestTests + build verification only (no publish)
Manual triggerVia Actions tab → "Run workflow"

Build times

Approximate durations:

  • Tests only: ~5 minutes
  • All binaries (16): ~30-45 minutes
  • Docker images: ~15-20 minutes
  • Total (on develop/master): ~60-80 minutes

Modifying the CI

Files to know:

  • .github/workflows/ci.yml - Main CI configuration
  • docker/Dockerfile - Docker image build instructions
  • src/main.rs - Version display logic

Before changing:

  1. Test locally if possible
  2. Use a feature branch
  3. Check CI passes on your PR before merging

Common CI Tasks

Add a new architecture: Edit .github/workflows/ci.yml → Add to matrix under relevant job

Change Docker tags: Edit .github/workflows/ci.ymldocker job → Determine Docker tags step

Update Rust version: Edit docker/Dockerfile → Change FROM rust:1.91-slim-trixie


Technical Details

Build Optimizations

All binaries use these Cargo profile settings:

[profile.release]
opt-level = "z" # Optimize for size
lto = true # Link-time optimization
codegen-units = 1 # Better optimization
strip = true # Remove debug symbols

Docker Image Labels

Images include OpenContainer metadata:

  • org.opencontainers.image.source - GitHub repository URL
  • org.opencontainers.image.revision - Git commit SHA
  • org.opencontainers.image.created - Build timestamp

View with: docker inspect uwucode/ygege:latest

Build environment variables

These are embedded during compilation:

  • BUILD_COMMIT - Git commit SHA
  • BUILD_DATE - ISO 8601 timestamp
  • BUILD_BRANCH - Branch name (develop/master)

Support

Found a bug? Open an issue

Need help? Check existing issues or start a discussion

Want to contribute? Read the contribution guidelines