Commit Graph

8 Commits

Author SHA1 Message Date
Ruslan Aliev
2e85043c20 Fix typos
Change-Id: I0ce87ec00d2b5974cf861d9c9685f23d7d0f5fc1
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
2020-09-21 02:49:33 -05:00
Kostiantyn Kalynovskyi
6a2fba6f21 Add events package
The package will have Event object, that would represent any event
that airshipctl can have, also this package provides Processor interface
that is to be used to process, print, or track progress of the executor
runners

Change-Id: I184408f7b6130653cdbabbe5e5adaac2dd758663
2020-07-07 09:44:22 -05:00
Kostiantyn Kalynovskyi
cd7e99ac15 Add more genernic Kubectl Factory interface
Adds FakeFactory function, that allows to inject custom handlers
for HTTP and Unstructured client, which in turn enables better
testing for kubernetes api related packages

Relates-To: #276
Relates-To: #238

Change-Id: Ic27352bdc64bfccb91cc6a49afa6164e4624b1e1
Closes: #276
2020-06-17 17:30:14 -05:00
Yasin, Siraj (SY495P)
641248f46b Fix Lint warnings: Missing comments for functions
* Added comments wherever missing for exported functions/constants

Change-Id: I0942e710077ba7c6ac35d661023c87070fe0a23b
Closes: #148
2020-05-19 16:54:13 +00:00
Yasin, Siraj (SY495P)
bc5dbed20f Aligned the function definiton to its signature
* The function definition for WithToDiscoveryClientByError and
  WithDynamicClientByError seems to be swapped by mistake.
* So aligned the function definiton to its signature

Change-Id: I7e293b148765f460d007aa4a6dc931defeb879b5
2020-04-16 11:07:23 -05:00
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
2020-04-09 08:35:59 -05:00
Alexander Hughes
7549fdbeb0 [#86] remove unused code
A number of items were identified by GoLand's code inspection as
being unused.  These are being removed in this change.

Change-Id: I0c8c0b5f5c33f2e715f991a02ddd63174758c533
Signed-off-by: Alexander Hughes <Alexander.Hughes@pm.me>
2020-03-10 19:15:04 +00:00
Kostiantyn Kalynovskyi
d588c73e38 [#20] Add kubectl apply wrapper package
The wrapper is called ApplyAdapter and is a struct, that has Apply(..)
method and some setters that allow to control kubectl apply behaviour

Addapter is expected to be used through Apply(..) function, which takes
slice of document.Document interface objects, writes them out to
temporary file system, from where they are picked up by kubectl Apply
module, and delivered to kubernetes cluster. The decision to use
temporary file system is based on the fact, that in current state
kubectl project currently only works with actual files, and ignores
io.Streams object, that is part of ApplyOptions struct, so it is
currently the only way to use it.

Change-Id: Idc5d79794149c00198f420d76cf9aa3b5264946e
2020-02-20 20:58:31 +00:00