Commit Graph

14 Commits (faa13c51adae311e187380972837d81ca60d3e54)

Author SHA1 Message Date
Zuul 4566efc325 Merge "improve logging" 3 years ago
Schiefelbein, Andrew 20d2a99190 improve logging
This will help on debugging and / or error messages which
will show what package and what line a message came from

This is pared down from what is currently being proposed for the UI
https://review.opendev.org/#/c/747473/

Change-Id: I68eb8b0141a8d56d5ea14aa623a25f9287ff1e75
3 years ago
Ruslan Aliev 160117af3a Use log module to determine current log level
As part of config refactoring process, it makes sense to
remove Debug field of AirshipCTLSettings and use log module
method as source of truth about current log level.

Change-Id: I42e3a9fd3b4e2778c71278f98a0d168421dfd2fb
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
Relates-To: #327
3 years ago
Ian Howell 07896b97c5 Add a prefix to the logger
This will make it easier to differentiate between airship log messages
and third-party log message (e.g. clusterctl)

Change-Id: I0b8a2fed58a6a673277f511267e2498c7e8d4c1b
3 years ago
Yasin, Siraj (SY495P) c25d223c7b Add copyright for missing files
* added license templates for go, bash & yaml in tools dir
* added a script that will add license information for all
    missing files. Type:  go, yaml, yml, sh
* skip adding license for all files within testdata
* Syntax:
   > ./tools/add_license.sh

* Skip license for manifests folder
* Added one extra line after licene for yaml files
* Added License after Hashbang for bash.
* Add an extra line after hashbang and before license
* Updated the go template to use multiline comments

New Files:
  1. tools/add_license.sh
  2. tools/license_go.txt
  3. tools/license_yaml.txt
  4. tools/license_bash.txt

Change-Id: Ia4da5b261e7cd518d446896b72c810421877472a
Realtes-To:#147
3 years ago
Dmitry Ukov e57b3ce4c0 Show isogen container logs if debug is enabled
Change-Id: I92c82eecdb35de22cc4da2326632b8af3aadd4cd
3 years ago
Ian Howell d775b2159a This updates the current unit tests for testify
This commit removes any assertion from Go's "testing" package,
preferring instead to use an assertion from the testify package. All
tests now have uniformity.

This also decrease the number of iterations in the password generation
test, decreasing test runtime tenfold

Change-Id: I8799110e93dfa19bebe9050528e865b4c991c3df
4 years ago
Ian Howell 062f59119f This isolates logging from the standard library
This commit adds a custom encapsulated Logger, which then has its
methods exposed in a controlled fashion. This prevents external
libraries from modifying things such as the flags passed to the logger,
or where it should output to.

Change-Id: Ide4321246b1277fcee51608aa95532b8696b9777
4 years ago
Ian Howell 6e41a56a7d Rename module to reflect its new location
Change-Id: I5c8c524c4d3f569b21b5b829722b3c49952cb0ab
4 years ago
Ian Howell 56a4824524 Fix unit tests 4 years ago
Ian Howell 68cfcf82ae Fix log tests 4 years ago
Ian Howell cbd1e048c9 Move the client objects out of the settings objects
* This also modifies the way that logging is handled
4 years ago
Ian Howell 7a34fd98d9 Change airshipadm to airshipctl 4 years ago
Ian Howell 7e2609d1e8 Add logging 4 years ago