Skip to main content

CICD

Project description

ONYX PACKAGE MANAGER

Short description or overview of what the project does.

Table of Contents

Installation

  1. Clone the project from Pipy:

    pip install onyxpm==0.0.24
    

First Steps After Installation

  1. After installing the project, locate the installation directory where Onyxpm has been installed. This directory is typically identified during the installation process. Make sure to note down this directory.

    C:\Users\User\AppData\Local\Programs\Python\Python312\Lib\site-packages\onyxpm\onyxpm.py
    
  2. Create PowerShell script files (.ps1) to set up both the source and target environments. The content of the .ps1 file should resemble the following:

    Example:
    python InstallationPath\onyxpm.py tenant set -t tenant -tn "tenant_name" -td "tenant_domain" -tu "tenant_username" -tp "tenant_password" -ti "tenant_id"
    

    OR Alternatively:

    cd InstallationPath
    CLI Commands
    

    Replace "InstallationPath" with the actual installation path where Onyxpm is installed. Execute the .ps1 file (.\setup.ps1) to configure and set up your environments. If the environment settings are correct, you'll see an env.conf file created in your project, which will be used for further operations.

  3. Execute the .ps1 files to set up your environment. You can use other CLI commands as shown below.

Usage

Below are examples demonstrating how to use the project's command-line interface (CLI). Replace onyxpm.py with the name of your CLI script if it's different.

Help

To view the available commands and options, run:

python onyxpm.py --help

Set Tenant Command

To set parameters for a specific tenant, use the following command:

python onyxpm.py tenant set -t tenant -tn "tenant_name" -td "tenant_domaine" -tu "tenant_username" -tp "tenant_password" -ti "tenant_id"

Example of the env.conf file:

#SOURCE
SOURCE_TENANTDOMAIN='https://example_domain.com'
SOURCE_TENANTID='1'
SOURCE_TENANTNAME='UAT'
SOURCE_TENANTUSERNAME='example@sourceusername.com'
SOURCE_TENANTPASSWORD='example_pwd'

List Tenants Command

To list the names of all tenants, use the following command:

python onyxpm.py tenant list

List Projects Command

To list the names of projects for a specific tenant, use the following command:

python onyxpm.py "project list" -t "tenant_name"

Dump Command

To dump data for a specific tenant to a specified folder, use the following command:

python onyxpm.py tenant dump -t "tenant_name" -f "destination_folder ./directory"

This command will dump data to the current directory of the tenant.

Compare Projects Command

To compare projects between source and target tenants for a specific project, use the following command:

python onyxpm.py project compare -ts "source_tenant" -tt "target_tenant" -p "project_name" 

Deploy Command

To deploy a script for a specific project from a source tenant to a target tenant, use the following command:

python onyxpm.py project deploy -i "file_type" -o "file_name" -p "project_name" -ts tenant_source -tt tenant_target

Example Usage: To deploy Report's (filetype (i): 'REPORT') from project SOPREMA (tenant source(ts): 'SOPREMA') to destination SOPREMAPROD (target tenant (tt): 'SOPREMAPROD'), use the deploy command in the following manner:

   python onyxpm.py project deploy -i REPORT -ts SOPREMA -tt SOPREMAPROD -p Démonstration

Writing and exceuting the

Command Parameters

  • -t: Set the tenant parameter.
  • -f: Set the folder parameter.
  • -o: Specify the name of an object.
  • -p: Specify the name of a project.
  • -ts: Specify the name of a source tenant.
  • -tt: Specify the name of a target tenant.
  • -i: Specify a keyword :
    • [CONNECTION, NOTIFICATION, DATAPIPELINE, FORM, SCHEDULE, SHELL_SCRIPT, SQL_SCRIPT, FILE_PROVIDER, VARIABLE, WORKFLOW, REPORT, WIDGET]

Project Structure

The structure of the project, including important directories and files.

OnyxCLi/
│
├── src/
│   └── onyxpm/
│      ├──onyxpm
│      ├── CLASSES/
│         ├── EnvConfElement.py
│         ├── NxComponent.py
│         └── ...
│      ├── LIBS_BUS/
│         ├── apply_transco.py
│         ├── compare_onyx_projects.py
│         └── ...
│      └── LIBS_CLI/
│          ├── action_1.py
│          ├── action_2.py
│          └── ...
├── tests/
├── env.conf
├── setup.py
├── requirements.txt
└── README.md

Want to Contribute ?

If you'd like to contribute to the project, follow these steps:

  1. Fork the repository
  2. Create a new branch (git checkout -b feature)
  3. Make your changes
  4. Commit your changes (git commit -m 'Add feature')
  5. Push to the branch (git push origin feature)
  6. Create a new pull request

License

MIT License

Copyright (c) 2020 NeuralNine

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

onyxpm-0.0.28.tar.gz (32.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

onyxpm-0.0.28-py3-none-any.whl (51.1 kB view details)

Uploaded Python 3

File details

Details for the file onyxpm-0.0.28.tar.gz.

File metadata

  • Download URL: onyxpm-0.0.28.tar.gz
  • Upload date:
  • Size: 32.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.4 CPython/3.12.7 Windows/11

File hashes

Hashes for onyxpm-0.0.28.tar.gz
Algorithm Hash digest
SHA256 38922593097331a03f9c7f46b4b95d055c7eeecb67dfdf505ed3c53fa5c2c5ca
MD5 af668dc2ebb7bd4691da5c84351c0871
BLAKE2b-256 2259df00eb40419397f4f9fe189f763491d193c5b956c178e4838053533fa407

See more details on using hashes here.

File details

Details for the file onyxpm-0.0.28-py3-none-any.whl.

File metadata

  • Download URL: onyxpm-0.0.28-py3-none-any.whl
  • Upload date:
  • Size: 51.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.4 CPython/3.12.7 Windows/11

File hashes

Hashes for onyxpm-0.0.28-py3-none-any.whl
Algorithm Hash digest
SHA256 c76232c7a49795475c5ebea213ce8d75f9dca0ae6aaf5727e5ff73df276a1cbc
MD5 85cbf7539a23cac87cdf2dae94fc2739
BLAKE2b-256 da9fcb4b51e110781a33ff921abeb3c9551e1fe5654dc1440ee20eb56ac2403c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page