action-organization-manager

command module
v0.0.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 9, 2022 License: MIT Imports: 13 Imported by: 0

README

action-organization-manager

github actions for organization manage

Features

  1. Features switch (Wiki,Issues...)
  2. Branchs protection

Input

  app_id:
    description: "github app id"
    required: true
  installation_id:
    description: "github app installation id"
    required: true
  private_key:
    description: "github app private key"
    required: true
  config_file:
    description: "manager config file"
    required: true

Uses

  1. Create and Install GitHub App in organization settings

  2. Get AppID (App setting -> General) and InstallationID (App setting -> Advanced -> Recent Deliveries -> Payload)

  3. Generate GitHub App Private Key and upload to organization secrets

  4. Add .github/workflows/org-mgr.yml to organization repository

    name: organization-manager
    on:
    push:
        paths: ["organization.yaml", ".github/workflows/org-mgr.yml"]
    
    jobs:
        job:
            name: organization-manager
            runs-on: ubuntu-latest
            steps:
            - uses: myml/action-organization-manager@v0.0.3
                with:
                app_id: $app_id
                installation_id: $installation_id
                private_key: ${{ secrets.APP_PRIVATE_KEY }}
                config_file: organization.yaml
    
  5. Add organization.yaml config file to organization repository

    organization: $organization_name
    settings:
    - repositories: [$repositories_name or regular expression]
        features:
        issues:
            enable: true
        wiki:
            enable: true
        projects:
            enable: true
        branches:
          $branche_name:
            dismiss_stale_reviews: true
            enforce_admins: true
            required_approving_review_count: 1
            required_status_checks:
            require_review: true
            strict: true
    

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL