Skip to content

Create Web-based Configuration Builder for Build Templates #1

@rohansen856

Description

@rohansen856

Summary

Create a minimal web interface that allows users to build configuration templates for the zlinux-artifacts-builder system through an intuitive form-based UI with dropdowns, selects, radio buttons, checkboxes, etc.

Currently, users need to manually create YAML configuration files for build templates. This requires understanding the schema and manually editing files like:

artifacts:
  - type: binary
    language: go
    build_script:
      repo_name: linux-on-ibm-z-scripts
      path: Go/1.21/build_go.sh
      args: ["--version", "1.21"]
      docker_image: ubuntu:20.04
  - type: rpm
  - type: container
    image_name: "{{repo_name}}"
    dockerfile: Dockerfile
    registry: ghcr.io
architecture: s390x
schedule: "{{global_schedule}}"
webhook: "{{global_webhook}}"

Proposed Solution

Build a web interface that:

Core Features

  • Form-based Template Builder: Visual form with appropriate input types for each configuration option
  • Dynamic Artifact Addition: Allow users to add/remove multiple artifacts with different types
  • Real-time YAML Preview: Show generated YAML as users fill the form
  • Template Validation: Client-side validation of required fields and valid combinations

UI Components Needed

  • Dropdowns:
    • Artifact types (binary, rpm, container, debian)
    • Programming languages (go, java, python, c/cpp)
    • Architecture selection (s390x, amd64, etc.)
    • Docker base images
  • Text Inputs:
    • Repository names, paths, image names
    • Build script arguments
    • Schedule expressions
  • Checkboxes:
    • Enable/disable features (webhook, schedule)
    • Optional components
  • Radio Buttons:
    • Single-choice options where applicable
  • Multi-select:
    • Build script arguments (array inputs)

Technical Requirements

  • Minimal dependencies (vanilla JS or lightweight framework)
  • Generate valid YAML output
  • Responsive design for various screen sizes
  • Export functionality (download generated config)

Example Workflow

  1. User selects "Go Binary" from artifact type dropdown
  2. Form dynamically shows Go-specific options (version, build script path)
  3. User adds additional artifacts (RPM, container)
  4. Real-time preview shows generated YAML
  5. User downloads or copies the final configuration

Acceptance Criteria

  • Web form covers all template configuration options from existing templates
  • Generated YAML is valid and matches manual template structure
  • Interface is intuitive for non-technical users
  • Supports multiple artifact types in single template
  • Includes validation and helpful error messages
  • Mobile-responsive design

Implementation Notes

  • Should integrate with existing template system in config/templates/
  • Consider hosting as static site or simple web service
  • May want to validate against actual schema used by orchestrator
  • Could potentially be served alongside main build system

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions