Ettore Di Giacinto
715ee1db08
Add unit test for creating docker repositories
2021-01-22 19:59:26 +01:00
Ettore Di Giacinto
a037bc545b
Add comment on required permission to unpack
2021-01-22 16:55:51 +01:00
Ettore Di Giacinto
d2e6409451
Add docker client unit test
2021-01-22 16:55:51 +01:00
Ettore Di Giacinto
a2df02e1bf
Add comments on repository files #159
2021-01-22 16:55:51 +01:00
Ettore Di Giacinto
928c305ff1
Respect metadata fields about the tree filename
...
This caused to always ignore what was explictly asked during repo
creation
2021-01-22 16:55:51 +01:00
Ettore Di Giacinto
a6e7a3059c
Respect artifact extension when populating cache
...
This caused cache to not hit correctly
2021-01-22 16:55:51 +01:00
Ettore Di Giacinto
9b2b877a53
Avoid to build images if already present
2021-01-22 16:55:51 +01:00
Ettore Di Giacinto
75fad993f3
Fixup repository revision bump
2021-01-22 16:55:51 +01:00
Ettore Di Giacinto
4b4c3a2e14
Adapt tests to new constructor changes
2021-01-22 16:55:51 +01:00
Ettore Di Giacinto
163f93067c
Temporarly rework genuinetools/img code for pull/unpack without Docker
2021-01-22 16:55:51 +01:00
Ettore Di Giacinto
91ea2ed99f
Make docker image repositories actually working
...
Several changes are included:
- Expose ensureDir in helpers, and call it in the Docker client. In
other implementations that was handled by CopyFile behind the scenes,
but that's not the case here
- Create accessor in Artifact to create Artifact objects from files.
This is handy when we have to carry over downloaded package content
into caches when artifacts are already verified
- Fix various issues around the imagePush flag, so now trees are pushed
forcefully each time
- Take into consideration the real artifact name when pushing single
files in the docker image. This behavior should be changed eventually,
because single files which aren't repository packages now are in its
own docker image, but we should have just one that brings the required
metadata alltogether.
2021-01-22 16:54:19 +01:00
Ettore Di Giacinto
dbd37afced
Add docker client #169
2021-01-22 16:54:19 +01:00
Ettore Di Giacinto
2f459c0469
Use only one docker image reference to push repository.
...
Instead of generating different images, which are harder to track and
clean, we generate a single image with various tags, corresponding to
the packages available in the repositories.
Tagging, and pushing separate images will be possible with the plugin
mechanism
2021-01-22 16:54:19 +01:00
Ettore Di Giacinto
ad455edafc
Allow to push images in create-repo
...
Add also the --force flag to allow image overwrite
Related to #169
2021-01-22 16:54:19 +01:00
Ettore Di Giacinto
d9286a1a1e
Download repository metadata with client DownloadFile, uniform downloads for Docker repositories
2021-01-22 16:54:19 +01:00
Ettore Di Giacinto
322fe72ef2
Generate repository metadata and packages for docker repository type
...
Drop image-repository on create-repo. In case of a docker repository, --output is the image reference to use.
Also restore default output build dir.
See also: #169
2021-01-22 16:53:52 +01:00
Ettore Di Giacinto
7390623e40
Don't warn user of accepting license in case of uninstall
...
Closes #160
2021-01-07 10:36:57 +01:00
Ettore Di Giacinto
bd0d2765aa
Mark executed finalizers at beginning
...
don't retry failing finalizers, but mark as executed right away
2021-01-04 17:04:20 +01:00
Ettore Di Giacinto
a81d0bc3a3
Build assertions when swapping
...
When we are swapping packages, we do not run the solver to gather things
to install, but we trust the given list when calling computeInstall. In this case, the assertion
returned by computeInstall is empty, as we force l.Options.NoDeps.
This change generates the assertion list while calling computeSwap so
it's available later when we call ExecuteFinalizer.
2021-01-02 21:28:54 +01:00
Ettore Di Giacinto
55ab1894e9
Add unit test for Uninstall in Installer
2020-12-29 22:58:03 +01:00
Ettore Di Giacinto
b81ce66914
Reduce download verbosity
2020-12-27 20:21:05 +01:00
Ettore Di Giacinto
f871111e50
Collect errors from finalizer runs
...
Instead of failing and depend on the --force flag, always execute
finalizer and collect errors to determine if install was successfull or
not
2020-12-25 10:35:09 +01:00
Ettore Di Giacinto
736c9470cf
Add db copy and clone
2020-12-19 17:45:50 +01:00
Ettore Di Giacinto
96e877fc0b
Allow uninstall to take multiple packages
...
And treat those as a list, instead of each single of them
2020-12-19 17:16:58 +01:00
Ettore Di Giacinto
525bfb5ebf
Respect --nodeps when calling Swap from the public interface
2020-12-19 15:26:18 +01:00
Ettore Di Giacinto
f4e2f32aff
Return candidate not found when appropriate
2020-12-19 14:57:42 +01:00
Ettore Di Giacinto
7cf650a8f6
Break Swap in computeSwap() and display uninstall dialog only when asked
2020-12-19 14:55:59 +01:00
Ettore Di Giacinto
1c9b821058
Drop unneeded if
2020-12-18 00:50:20 +01:00
Ettore Di Giacinto
0e21548bc0
Lookup uninstall and Install in installer.Swap
...
In this way we resolve selectors from user inputs
2020-12-18 00:49:51 +01:00
Ettore Di Giacinto
d97e606a31
Adapt fixtures and tests
2020-12-12 12:10:24 +01:00
Ettore Di Giacinto
9eef7e5c6d
Clean up if condition
2020-12-09 22:58:33 +01:00
Ettore Di Giacinto
332824fd42
Fail in the downloader goroutine and don't skip errors with force
2020-12-09 22:56:55 +01:00
Ettore Di Giacinto
737fbdbdc1
Don't make artifact checksum skippable
2020-12-09 21:31:07 +01:00
Ettore Di Giacinto
59d78c3f5c
While upgrading always use nodeps while computing uninstall
2020-12-07 17:20:55 +01:00
Ettore Di Giacinto
d479ada402
Don't consider deps while uninstalling during package Swap
...
Beside being forced, it also doesn't need to look deep into the deps, as
we already have precalculated those
2020-12-06 22:48:48 +01:00
Ettore Di Giacinto
7b800c9a20
Pre-compute swap step
...
Otherwise, while upgrading, it could happen that package dependencies
aren't downloaded before, and they would just be installed in the middle
of installation, after removal already happened.
2020-12-06 22:11:17 +01:00
Ettore Di Giacinto
67c43eb936
Don't bail out if package is installed and we have a list
2020-12-03 20:03:37 +01:00
Ettore Di Giacinto
cf80e5fc09
Resolvers might omit packages
2020-12-03 18:53:57 +01:00
Ettore Di Giacinto
d668d8344b
Accept selectors on uninstall and fixup failure logic
2020-12-03 18:32:24 +01:00
Ettore Di Giacinto
b17ac447f1
Display matched packages only, and check if they are available
2020-12-03 17:25:29 +01:00
Ettore Di Giacinto
9423b7c1e3
Add image build events, and add luet replace
...
Enhance also some commands descriptions
2020-12-02 18:24:35 +01:00
Ettore Di Giacinto
0fe30ddcfd
Add ability to interpolate during build
...
Now build takes a --values argument, which is a yaml file that can be
used to interpolate the specs that are going to be compiled.
2020-11-28 15:47:29 +01:00
Ettore Di Giacinto
18d9366bca
Minor fixes
2020-11-24 18:27:49 +01:00
Ettore Di Giacinto
db1b190fb5
Minor fixup and cleanups around the new prompt feature
2020-11-23 18:20:30 +01:00
Ettore Di Giacinto
b349665ff2
Add user prompts
...
Fixes #106
2020-11-22 23:43:29 +01:00
Ettore Di Giacinto
53ab0e0dd2
Merge pull request #151 from mudler/download-progress-bar
...
Download progress bar
2020-11-20 19:00:25 +01:00
Daniele Rondina
60d5c9dfd5
Add download progress bar
2020-11-20 18:12:23 +01:00
Ettore Di Giacinto
f2df3faee5
Now Uninstall takes multiple packages
2020-11-19 18:05:27 +01:00
Daniele Rondina
f9a7113ab9
client/http: Add experimental download info
2020-11-19 00:56:28 +01:00
Ettore Di Giacinto
0e46e763d5
Move bus implementation to a separate repo, hook to events in luet
2020-11-13 18:25:44 +01:00