Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove python script.py to reduce dependencies #1899

Closed
mlodic opened this issue Sep 13, 2023 · 1 comment · Fixed by #2060
Closed

Remove python script.py to reduce dependencies #1899

mlodic opened this issue Sep 13, 2023 · 1 comment · Fixed by #2060
Assignees
Labels
maintenance Issues that requires updating dependencies and overall modernity of the project

Comments

@mlodic
Copy link
Member

mlodic commented Sep 13, 2023

We should reduce the overall dependencies to install.
We should transform this script in a bash script for better compatibility.

We should take this refactor to solve this issue altogether

@mlodic mlodic added the maintenance Issues that requires updating dependencies and overall modernity of the project label Sep 13, 2023
@ZypherNight
Copy link

we should do the following thing:

  1. Use standard libraries: Whenever possible, use standard libraries instead of third-party libraries. This will reduce the number of dependencies that need to be installed.
  2. Use lightweight libraries: If you do need to use a third-party library, choose a lightweight library that has few dependencies.
  3. Bundle dependencies: If you have a number of dependencies, you can bundle them into a single package. This will make it easier to install and manage the dependencies.

and also Use bash syntax throughout the script

@fgibertoni fgibertoni linked a pull request Jan 9, 2024 that will close this issue
22 tasks
@mlodic mlodic closed this as completed in 5a2e628 Jan 12, 2024
mlodic added a commit that referenced this issue Jan 12, 2024
* Using correct pipeline to manage visualizers (#2044)

* Using correct pipeline to manage visualizers

Signed-off-by: 0ssigeno <s.berni@certego.net>

* Fix tests

Signed-off-by: 0ssigeno <s.berni@certego.net>

---------

Signed-off-by: 0ssigeno <s.berni@certego.net>

* tweaks to docs

* added exception catcher for Cymru analyzer

* fixed bug in info column in the plugin section

* fixed bug in multiple observable analysis (#2047)

* fixed bug in multiple observable analysis: all observable had the type of the first one

* linter

* restore IP regex to accept also IPv6

* removed env in the toolbar (#2050)

* removed env in the toolbar

* linter

* Dashboard improv: add button to filter for the user's org only (#2028)

* frontend : add switch for user's org

Signed-off-by: Shivam Purohit <shivampurohit900@gmail.com>

* backend:add endpoint for the req

Signed-off-by: Shivam Purohit <shivampurohit900@gmail.com>

* initial backend url

Signed-off-by: Shivam Purohit <shivampurohit900@gmail.com>

* improve frontend logic

Signed-off-by: Shivam Purohit <shivampurohit900@gmail.com>

* add user org filter

Signed-off-by: Shivam Purohit <shivampurohit900@gmail.com>

* fix : try except block

Signed-off-by: Shivam Purohit <shivampurohit900@gmail.com>

* remove redundant url endpoints

Signed-off-by: Shivam Purohit <shivampurohit900@gmail.com>

* remove unnecessary commented code

Signed-off-by: Shivam Purohit <shivampurohit900@gmail.com>

* add hide component logic

Signed-off-by: Shivam Purohit <shivampurohit900@gmail.com>

* rename props

Signed-off-by: Shivam Purohit <shivampurohit900@gmail.com>

* reduce redundant code via functions

Signed-off-by: Shivam Purohit <shivampurohit900@gmail.com>

* convert get_org_members to static

Signed-off-by: Shivam Purohit <shivampurohit900@gmail.com>

* remove logger changes

Signed-off-by: Shivam Purohit <shivampurohit900@gmail.com>

* remove comments and rename variables

Signed-off-by: Shivam Purohit <shivampurohit900@gmail.com>

* remove console statement

Signed-off-by: Shivam Purohit <shivampurohit900@gmail.com>

* refactor get_org_members

Signed-off-by: Shivam Purohit <shivampurohit900@gmail.com>

* fix:prettier

Signed-off-by: Shivam Purohit <shivampurohit900@gmail.com>

---------

Signed-off-by: Shivam Purohit <shivampurohit900@gmail.com>

* adjusted README

* Added check for path

Signed-off-by: 0ssigeno <s.berni@certego.net>

* Fix corner case for multiple playbook

Signed-off-by: 0ssigeno <s.berni@certego.net>

* Fix pointers

Signed-off-by: 0ssigeno <s.berni@certego.net>

* Backend always decide the classification

Signed-off-by: 0ssigeno <s.berni@certego.net>

* Job bi (#2052)

* job bi

Signed-off-by: 0ssigeno <s.berni@certego.net>

* More

Signed-off-by: 0ssigeno <s.berni@certego.net>

* Job bi

Signed-off-by: 0ssigeno <s.berni@certego.net>

* Migration

Signed-off-by: 0ssigeno <s.berni@certego.net>

* Fix

Signed-off-by: 0ssigeno <s.berni@certego.net>

* Fix

Signed-off-by: 0ssigeno <s.berni@certego.net>

* Added playbook in the elastic template

Signed-off-by: 0ssigeno <s.berni@certego.net>

* Fix

Signed-off-by: 0ssigeno <s.berni@certego.net>

* Missin migrations

Signed-off-by: 0ssigeno <s.berni@certego.net>

---------

Signed-off-by: 0ssigeno <s.berni@certego.net>

* Bump pillow from 10.0.1 to 10.2.0 in /requirements (#2055)

Bumps [pillow](https://github.com/python-pillow/Pillow) from 10.0.1 to 10.2.0.
- [Release notes](https://github.com/python-pillow/Pillow/releases)
- [Changelog](https://github.com/python-pillow/Pillow/blob/main/CHANGES.rst)
- [Commits](python-pillow/Pillow@10.0.1...10.2.0)

---
updated-dependencies:
- dependency-name: pillow
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump checkdmarc from 4.8.4 to 5.2.7 in /requirements (#2054)

Bumps [checkdmarc](https://github.com/domainaware/checkdmarc) from 4.8.4 to 5.2.7.
- [Changelog](https://github.com/domainaware/checkdmarc/blob/master/CHANGELOG.md)
- [Commits](https://github.com/domainaware/checkdmarc/commits)

---
updated-dependencies:
- dependency-name: checkdmarc
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump quark-engine from 23.9.1 to 23.12.1 in /requirements (#2045)

Bumps [quark-engine](https://github.com/quark-engine/quark-engine) from 23.9.1 to 23.12.1.
- [Release notes](https://github.com/quark-engine/quark-engine/releases)
- [Commits](quark-engine/quark-engine@v23.9.1...v23.12.1)

---
updated-dependencies:
- dependency-name: quark-engine
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump flake8 from 6.1.0 to 7.0.0 in /requirements (#2056)

Bumps [flake8](https://github.com/pycqa/flake8) from 6.1.0 to 7.0.0.
- [Commits](PyCQA/flake8@6.1.0...7.0.0)

---
updated-dependencies:
- dependency-name: flake8
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Frontend - fixed runtime config bugs (#2064)

* fixed runtime config bugs

* restored old comment

---------

Co-authored-by: Daniele Rosetti <d.rosetti@certego.net>

* updated frontend dependencies

* Refactoring of start.py script. Closes #1899 and #1866  (#2060)

* Removed initialize.sh root execution

* Remove sudo command from installation

* Added python3-venv installation

* Dropped support for docker compose V1

* Added redirection to stderr

* Dropped support for docker compose V1

* Fixed download directory of script

* Changed shebang for better compatibility

* First not finished bash script

* Formatting fix

* Added parameter checks

* Added other parameters check

* Fixed wrongly used check

* Removed start() function

* Used exact string matching for parameters

* Added mandatory argument parsing

* Moved declaration of array inside of logical function

* Added main parameter case

* Added help function

* Added default version to help

* Completed help function

* Added argument parsing

* Added help option

* Fixed subtle error with bash logic values

* Most of the work done

* Working docker cmd

* Added project directory specification

* Removed unused function

* Improved error message

* Removed reduntand if condition

* Added checks for empty strings

* Removed pycharm warnings

* Fixed IntelOwl version

* Fixed some bugs

* Fixed wrong for index

* Fixed git checkout

* Removed wrongly placed comment

* Removed python pre-requirements depencency

* Added execution of initialize.sh from start

* Entering venv

* Removed unused echo

* Added check for docker group

* Updated docs to use new startup script

* Fixed typo in doc

* Changed generic code blocks to bash

* Add curl dependency

* Add curl dependency

* Re added pre-requirements for compatibility

* Removed old occurrences of start.py

* Added test docker file for integrations

* Added manual usage to doc

* Removed python3 and venv dependency

* Updated major release informations

* Removed python and venv dependency for start

* Removed python and venv dependency for start from docs

* Made code-review-doctor happy

* Improved installation doc

* Added absolute path for application_restart

* Updated docs

* added deprecation notice

---------

Co-authored-by: Matteo Lodi <30625432+mlodic@users.noreply.github.com>

* Fixed creating a playbook with an existing tag (#2057)

* changed playbook serializer

* deepsource

---------

Co-authored-by: Matteo Lodi <30625432+mlodic@users.noreply.github.com>

* bump and changelog

---------

Signed-off-by: 0ssigeno <s.berni@certego.net>
Signed-off-by: Shivam Purohit <shivampurohit900@gmail.com>
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Simone Berni <simone.berni2@studio.unibo.it>
Co-authored-by: Daniele Rosetti <d.rosetti@certego.net>
Co-authored-by: Daniele Rosetti <55402684+drosetti@users.noreply.github.com>
Co-authored-by: Shivam Purohit <shivampurohit900@gmail.com>
Co-authored-by: 0ssigeno <s.berni@certego.net>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Martina Carella <m.carella@certego.net>
Co-authored-by: fgibertoni <152909479+fgibertoni@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
maintenance Issues that requires updating dependencies and overall modernity of the project
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants