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

Changes for pip and Cachito compatibility #9

Merged
merged 6 commits into from Jan 27, 2022

Conversation

compi-migui
Copy link

These changes enable container-first (container from source) builds using pip and Cachito.

Things not included here, and which we may want to do:

  • Change Makefile to build and install using pip
  • Change Dockerfile to not rely on RPMs

Copy link
Member

@mrunge mrunge left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you, this looks good

@mrunge
Copy link
Member

mrunge commented Jan 27, 2022

This is still marked as work in progress. Once you are fine with this, we can merge it.

@compi-migui compi-migui marked this pull request as ready for review January 27, 2022 13:53
@compi-migui compi-migui merged commit 321afe1 into infrawatch:master Jan 27, 2022
@leifmadsen leifmadsen mentioned this pull request Oct 13, 2022
leifmadsen pushed a commit that referenced this pull request Oct 13, 2022
* Add setup.py for pip compatibility

This allows prometheus_webhook_snmp to be installed using pip install.

* Add requirements and build requirements, all with locked versions

Cachito requires locking all versions to work. It is also generally a good thing to do.

* Dockerfile: install with pip instead of RPMs
leifmadsen added a commit that referenced this pull request Oct 18, 2022
* Fix issue when passing common args to the Docker image.

Signed-off-by: Volker Theile <vtheile@suse.com>

* Allow users to customize the command via ARGS and RUN_ARGS environment variables.

Signed-off-by: Volker Theile <vtheile@suse.com>

* Update RPM spec and Debian changelog.

Signed-off-by: Volker Theile <vtheile@suse.com>

* Fix issue in MIB. 'prometheusAlertNotificationRawData' needs to be a 'DisplayString'.

Signed-off-by: Volker Theile <vtheile@suse.com>

* Add 'Docker' section to README.

Signed-off-by: Volker Theile <vtheile@suse.com>

* Update README.

Signed-off-by: Volker Theile <vtheile@suse.com>

* Bump pyyaml from 5.1 to 5.4

Bumps [pyyaml](https://github.com/yaml/pyyaml) from 5.1 to 5.4.
- [Release notes](https://github.com/yaml/pyyaml/releases)
- [Changelog](https://github.com/yaml/pyyaml/blob/master/CHANGES)
- [Commits](yaml/pyyaml@5.1...5.4)

Signed-off-by: dependabot[bot] <support@github.com>

* - Improve tox.ini
- Fix code

* Add option to enable HTTPS

Add option to enable HTTPS

* Update changelog.

Signed-off-by: Volker Theile <vtheile@suse.com>

* Add a Dockerfile

* Run dnf clean all after install

That should save some size

* Fix the path and add python3-prometheus_client

* Fedora on Dockerhub still on f31

* Change order of arguments

* Add debugging tools

* Quay has not fedora 32

* Add debug level

* Remove snmp timeout and retries for now

* Update spec file for Fedora

* Fix systemd_pre in spec file

systemd_pre was missing its %

* Address issues from the review

- %pre scripts (missing %)
- License
- silence %setup

* Adjust Dockerfile to use packages

also change package build to also build on Centos8

* Use quay.io as the base image repository (#5)

Use quay.io to avoid issues building from docker.io and quota overuse.

Drop deprecated MAINTAINER option. Remove unused commented line. Also
remove telnet package which is not necessary to the operation of this
container image.

* migrate ci (#6)

* Add initial CI

* Only lint Dockerfile

* Address linting issues

* Add .hadolint.yaml

Add .hadolint.yaml so that DL3041 can be ignored. We implicitly want the latest
versions (unpinned) in the top branch.

* Enable pip installs and Cachito compatibility (#9)

* Add setup.py for pip compatibility

This allows prometheus_webhook_snmp to be installed using pip install.

* Add requirements and build requirements, all with locked versions

Cachito requires locking all versions to work. It is also generally a good thing to do.

* Dockerfile: install with pip instead of RPMs

* Rebase prometheus_webhook_snmp.py against upstream

Apply changes from
SUSE@4c58245
against our prometheus_webhook_snmp/ directory where we moved the main
binary into from the root directory.

* Update linting tool

Signed-off-by: Volker Theile <vtheile@suse.com>
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Volker Theile <vtheile@suse.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Nam Xuan Nguyen <nam.xuan.nguyen@est.tech>
Co-authored-by: Matthias Runge <mrunge@redhat.com>
Co-authored-by: Chris Sibbitt <csibbitt@redhat.com>
Co-authored-by: Miguel Garcia <miguelgar27@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants