GithubHelp home page GithubHelp logo

alcli's Introduction

Build Status Windows Build PyPI version

Installing the Alert Logic CLI

The pip package manager for Python is used to install, upgrade and remove Alert Logic CLI.

Installing the current version of the Alert Logic CLI

Alert Logic CLI only works on Python 3.7 or higher. Please follow this instructions on how to install Python on your system: https://www.python.org/downloads/

Use pip3 to install the Alert Logic CLI

$ pip3 install alcli --upgrade --user

Make sure to use --user to to install the program to a subdirectory of your user directory to avoid modifying libraries used by your operating system.

Windows installer

For windows users there is self-contained Alert Logic CLI distribution is available, please download latest version from here:

Alternatively, please view history of the releases.

Upgrading to the latest version of the Alert Logic CLI

We regularly introduce support for new Alert Logic services. We recommend that you check installed packages version and upgrade to the latest version regularly.

$ pip3 install --upgrade --force-reinstall alcli

Configure the Alert Logic CLI with Your Credentials

Before you can run a CLI command, you must configure the Alert Logic's CLI with your credentials.

By default, alcli uses ~/.alertlogic/config configuration file in a user's home directory. File can contain multiple profiles. Here's an example of a configuration file that has credentials for an integration and production deployments:

[default]
access_key_id=1111111111111111
secret_key=eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee
global_endpoint=integration

[production]
access_key_id=2222222222222222
secret_key=dddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddd
global_endpoint=production

The location of the configuration file can be also specified by setting ALERTLOGIC_CONFIG environment variable to contain file's location.

Notes:

--query option requires JMESPath language expression. See http://jmespath.org/tutorial.html for language tutorial.

alcli's People

Contributors

anton-b avatar carlisom avatar daniel-zinov avatar dependabot[bot] avatar ebrown-al avatar evanbrown96 avatar james-bellamy avatar mikebenza avatar msayler avatar ptrakhtman avatar raghavkarol avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

alcli's Issues

debug option logs AIMS token

Need to sanitize/override session logging here so we don't expose the AIMS token of the request—it's going to be common to request people to use --debug to trace problems, and we can't have that there.

2020-05-07 16:41:35,328 - MainThread - almdrlib.session - DEBUG - Calling 'get' method. URL: 'https://api.global-services.us-west-2.global.alertlogic.com/aetag/v1/MUMBLE/tags/paths/IncidentSeverityMap'. Params: '{}' Headers: '{'x-aims-auth-token': 'REDACTED'}' Cookies: '{}' Args: '{}'
DEBUG:almdrlib.session:Calling 'get' method. URL: 'https://api.global-services.us-west-2.global.alertlogic.com/aetag/v1/MUMBLE/tags/paths/IncidentSeverityMap'. Params: '{}' Headers: '{'x-aims-auth-token': 'REDACTED'}' Cookies: '{}' Args: '{}'

Conflicting version of pyyaml

Conflicting version of pyaml

PyYAML==5.1.2

https://github.com/alertlogic/alertlogic-sdk-definitions/blob/master/requirements.txt

ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.
alcli 1.0.46 requires pyyaml==5.1.2, but you have pyyaml 5.4 which is incompatible.

Should we do away with the requirement for a specific version?

alcli doesn't report missing profile or config file

Description

If you specify a profile with --profile, alcli won't let you know if a) the configuration file doesn't exist, or b) that profile can't be found in the file.

What I Did

> cat ~/.alertlogic/config
[production]
access_key_id = blahblah
secret_key = hunter2
> alcli --profile banana aims get_account_details --account_id 1234
Access Denied

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.