Giter Club home page Giter Club logo

katello-publish-content-view's Introduction

katello-publish-content-view

This script publishes a new version of a Katello Content View if the last version of a Content View is not up-to-date.

Prerequisite

Python 3.6+

Hot to use

Clone this repo and edit config.yml:

$ git clone https://github.com/brisa-dev/katello-publish-content-view.git
$ cd katello-publish-content-view
$ vi config.yml

Change config.yml with your custom data:

envs:
  lab:
    organization_id: 1
    username: some_user
    password: some_pass
    api_url: https://katello.example.io

Run script:

$ ./run.py --env lab # change config.yml with your custom variables

Read run.log file to see the output.

$ cat run.log

If all Content View is up-to-date you will receive the message bellow:

--- Initializing Katello Content View Checker --- 
It's now       : 2022-06-03 10:39:27 
Content view   : zabbix 
Last Published : 2022-06-02 21:29:17 
Status         : It's not necessary to publish a new version for this Content View 

If a new version of a Content View was created you will receive the message bellow:

--- Initializing Katello Content View Checker --- 
It's now       : 2022-06-03 10:44:06 
Content view   : zabbix 
Last Published : 2022-06-02 21:29:17 
Status         : It's necessary to publish a new version for this Content View 
Action         : Creating a new version of a Content View... 
Action status  : Success! 

Flow

sequenceDiagram
    run->>get_content_views: Give me the Content View Data
    get_content_views-->>run: return Content View Data
    get_content_views->>get_repository_info: Please, give me the repository data.
    get_repository_info-->>get_content_views: return Repository Data
    loop
      run-->run:Compare dates between Content View and Content View Repositories
      alt If Content View is not up-to-date
          run->>publish_new_content_view: Publish a new version of Content View
      end
    end

katello-publish-content-view's People

Contributors

ambrisolla avatar

Watchers

 avatar

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.