Code Monkey home page Code Monkey logo

gitlab-groups-filling-with-users's Introduction

GitLab groups filling with users

Automatically recursively adding a list of users to all GitLab groups.

This can be useful for GitLab administration when you need to add service accounts to all groups, such as dependabot, sonarqube, and other robot accounts for automation.

You are expected to run once or run on a schedule.

Environment Variables

  • GITLAB_URL=https://gitlab.zyfra.com - GitLab server URL
  • GITLAB_PRIVATE_TOKEN==None - Private access token. Normal access will allow you to grant rights no higher than the existing one and only for available groups. To manage an entire GitLab instance, it is better to use a token with sudo rights
  • GITLAB_FILLING_USERS=[] Comma-separated list of GitLab user IDs to add to groups.
    Example: GITLAB_FILLING_USERS=13,14,22
  • GITLAB_USERS_ACCESS_LEVEL=30 - Access level to be assigned to users
    • 10 - Guest
    • 20 - Reporter
    • 30 - Developer (default)
    • 40 - Mainteiner
    • 50 - Owner
  • GITLAB_EXCLUDE_GROUPS=[] Comma-separated list of GitLab groups to be ignored at run time.
    Example: GITLAB_EXCLUDE_GROUPS=10,42
  • SKIP_BLANK_GROUPS=True - Skip adding users to empty groups (groups that have no projects)
  • SKIP_NESTED_GROUPS=True - Skip adding users to nested groups, the user will inherit access from the parent group anyway.
  • LOG_LEVEL=INFO

Container Image

Run Locally

Clone this repository and go into it, run:

python -m venv .venv
pip install --upgrade pip
pip install --upgrade wheel
pip install --upgrade --requirement requirements.txt
. .venv/bin/activate
cp .env .env.example
editor .env
./app.py

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.