Commit Graph

1691 Commits

Author SHA1 Message Date
Kun Lu ccaa38d31f
Add s390x support to docker images (#1749)
* Add s390x support to docker images

1. add s390x support to docker images `executor`, `executor(slim)`,
   `executor(debug)` and `warmer`. Fixes #1462 and #1665.

2. Address the building issue of dependency `docker-credential-gcr`
   in Dockerfiles. This issue was introduced when recent commits
   in `docker-credential-gcr` removed the Makefile.

Signed-off-by: Kun-Lu <kun.lu@ibm.com>

* Add s390x support to all images except debug image

* Add s390x support to images.yaml

* Fix ld64.so.1 not found issue on s390x

* Add a comment for copying /lib from busybox container on s390x
2022-01-06 11:19:26 -05:00
Dawei Ma ee2249b3d5
fix: ARG/ENV used in script does not invalidate build cache (#1688) (#1693) 2021-12-30 12:51:00 -05:00
ankitm123 e62c80ed19
fix: change the name of the acr cred helper (#1865)
Signed-off-by: ankitm123 <ankitmohapatra123@gmail.com>
2021-12-29 08:28:32 -05:00
Jason Hall 633f555c5c
Fix implicit GCR auth (#1856)
* Fix implicit GCR auth

* boilerplate
2021-12-28 20:34:32 -05:00
Jason Hall 129df249c9
Log full image ref by digest when pushing an image (#1857) 2021-12-28 07:13:11 -06:00
Jason Hall 7207dca03a
Remove GitHub Actions concurrency limits (#1858) 2021-12-27 15:08:05 -05:00
Andrei Kvapil 2ea368dde8
tar: read directly from stdin (#1728)
* tar: run directly from stdin

* export UnTar function
2021-12-26 07:09:26 -05:00
Guillaume Calmettes d2f3e896cd
Fix regression: can fetch branches and tags references without specifying commit hashes for private git repository used as context (#1823)
* [FIX] can fetch tags and branches refs without specifying commit hashes

* [ENH] more precise comment
2021-12-24 15:13:45 -05:00
Andrei Kvapil e38b0c8d90
Fix calculating path for copying ownership (#1859)
* Fix calculating path for copying ownership

* fix CI
2021-12-24 07:09:53 -05:00
Andrei Kvapil 7065921aa4
Fix copying ownership (#1725)
* fix uid, gid overriding

* fix ownership for staging building

* add integration test

* add check for ignored files

* improve errors
2021-12-23 13:25:55 -05:00
jeunii 54395fc944
Fix typo (#1825) 2021-12-23 12:03:20 -05:00
Lars Seipel ac1a703731
Fix possible nil pointer derefence in fs_util.go (#1813)
When os.Stat returns an error different from ErrNotExist,
mkdirAllWithPermissions may panic with a nil pointer
derefence due to insufficient error checking.

Avoid the panic by bailing out, returning the error to the
caller.
2021-12-23 11:37:27 -05:00
ygelfand b3ec974cfc
include auth when fetching specific specs (#1796)
Signed-off-by: ygelfand <yuri@shlitz.com>
2021-12-23 11:36:19 -05:00
Sebastiaan Tammer 2cb0387758
Fix broken anchor link (#1804) 2021-12-23 11:35:21 -05:00
Travis DePrato ee95be1e27
Use pax tar format (#1809)
* Use PAX tar format

* Add test case
2021-12-23 11:35:00 -05:00
Bernardo Marques 7ae8e7d740
Update readme insecure flags (#1811)
* Clarify usage of --skip-tls-verify-registry argument

Referring to --skip-tls-verify-registry as a "flag" is misleading since
command line flags usually require no value. Thus, the documentation
is updated to match the behavior of the command line argument.

* Clarify usage of --insecure-registry argument

Referring to --insecure-registry as a "flag" is misleading since
command line flags usually require no value. Thus, the documentation
is updated to match the behavior of the command line argument.
2021-12-23 11:32:39 -05:00
Dávid Szakállas 840923b798
add documentation on ACR cred helper (#1831) 2021-12-23 11:32:17 -05:00
François JACQUES 5c81fa5774
Fixes #1837 : keep file capabilities on archival (#1838)
Signed-off-by: JACQUES Francois <hypnoce@donarproject.org>
2021-12-22 20:05:39 -05:00
Jason Hall 17f5e55530
Use setup-gcloud@v0.3.0 instead of @master (#1854) 2021-12-22 20:04:49 -05:00
Jason Hall 59c2d2d08f
Collapse integration test workflows into one config (#1855)
* Collapse integration test workflows into one config

Remove last traces of Travis, including env vars and `make travis-setup`
and badges in README

* fix lint

* make integration tests pass on PRs
2021-12-22 20:04:40 -05:00
Jason Hall b1b6962726
Share the Go build cache when building in Dockerfiles (#1853)
On my machine this makes image rebuilds go from ~5m to 1.5s.

This also required setting DOCKER_BUILDKIT=1 in integration test image
builds.

I also took the opportunity to bump the Go version used in those tests
to Go 1.17 to match the image build processes, and tidied up the
workflow files a bit too (renaming for consistency, typos, whitespace,
etc.)
2021-12-22 12:43:12 -05:00
Jason Hall 710650da73
Call cosign sign --key (#1849) 2021-12-21 12:40:06 -05:00
Jason Hall 6e500ecad9
Consolidate PR and real release workflows (#1845)
* WIP: consolidate PR and real release workflows

- push and sign an image tagged for every push to the repo (e.g., merged PRs)
- push and sign for tag pushes, with release tags
- build but don't push for opened PRs

WIP because I need to test more with the tag flow, but pushes worked in
my fork.

* apply release tags, uncomment kms stuff

* Tag images correctly during releases

* review feedback
2021-12-20 22:02:12 -05:00
Jason Hall f694212385
Use golang:1.17 and build from reproducible source (#1848)
* cleanup: Correctly use buildx TARGETARCH

* undo changes to Go version

* Use golang:1.17 and build from reproducible source

This change updates the Go version used to build kaniko and credential
helpers to Go 1.17, which uses Go modules by default. This means that we
can build outside of $GOPATH, from source fetched from the Go module
proxy.

This change also simplfies our builds of credential helpers to simply
`go install` them at a pinned version, for reproducibility and
simplicity.

This also changes `make images` and `make push` to build and push the
slim executor image as well.
2021-12-20 22:01:37 -05:00
Jason Hall 0fd1058782
Attempt to speed up PR image builds by sharing a cache (#1844)
docker/setup-buildx-action actually provides first-class support for
the GitHub Actions cache (though experimental). This should make builds
much faster. Previous configuration wasn't properly configuring caching,
as far as I can tell.

This also takes advantage of GitHub Actions matrix support to more
concisely express the build parameters then execute the same steps on
them, which makes it clearer that the builds are all fundamentally doing
the same thing.
2021-12-17 22:17:05 -05:00
Matt Moore c87f8efd07
Start keyless signing kaniko releases (#1841) 2021-12-17 19:52:51 -05:00
Matt Moore 22f76bb65d
Sign digests not tags. (#1840)
The logic that was in here was signing the tags we publish, which has a race.  Also since what cosign signs is actually the digest, this was signing 3x where we really only need one call.
2021-12-17 18:43:15 -05:00
Matt Moore 2e8a13943f
Bump the cosign version (a lot) (#1839)
The cosign version being used was ancient.  This catches us up to 1.4.1 (latest).

I was also eyeballing the very redundant jobs in `release.yaml` for a subsequent refactoring to make this a matrix job, so there are a couple of trivial cleanups related to this.
2021-12-17 17:51:28 -05:00
Matt Moore 49f0154b3f
Fix the e2e K8s test (#1842)
* Debugging the integration testing.

It seems to be consistently failing (also fix a typo in the file/leg name).

I'm disabling `-v` for `go test` because it interleaves the test output in ways that make it painful to read a single failing test's output when `t.Parallel` is involved.

* Try swapping registry:2 for the registry add-on

* Drop logf and make Logger private
2021-12-17 14:43:38 -05:00
Jason Hall 78808c9070
Fix syntax error in release.yaml (#1800) 2021-12-02 13:50:05 -05:00
Tejal Desai ee31dc93b6
Revert "Support mirror registries with path component (#1707)" (#1794)
* Revert "Support mirror registries with path component (#1707)"

This reverts commit 4e218f2162.

* fix tests and add co-sign back
2021-10-20 19:13:24 -07:00
Tejal Desai 4e841f2cd6
Better Self Serve instructions 2021-10-19 20:40:41 -07:00
Tejal Desai 28a6bdce78
Update CHANGELOG.md 2021-10-19 19:28:45 -07:00
wwade 82fc94d930
git: accept explicit commit hash for git context (#1765)
* git: accept explicit commit hash for git context

When checking out code from non-github repositories, the typical
assumptions may not be valid, e.g. that the only interesting
non-branch commits have ref names starting with refs/pull. A specific
example is fetching an un-merged commit from a gerrit repository by
commit hash.

This change just looks at the second part of the git context path and
checks if it's a SHA commit hash, and if so, will fetch and check out
this commit after cloning the repository.

Sample context argument:

    https://github.repo/project#e1772f228e06d15facdf175e5385e265b57068c0

* ci: fix test script to recognize any non-zero exit as an error

hack/linter.sh didn't properly install golangci-lint in hack/bin as I
already have another version of golangci-lint on my PATH, but then it
failed to execute because it was looking for it specifically in
hack/bin.

When the executable is not found, the exit code is 127 instead of 1,
and so test.sh ignored the error.

Two fixes:

1. `test.sh`:
  - Use `if (script) ...` instead of assigning / checking a result
    variable to determine if each validation script passed or failed.

2. `hack/linter.sh`:
  - Instead of checking for golangci-lint on the path, just
    specifically check for an executable file (`test -x`) in the
    expected location.

Co-authored-by: Wade Carpenter <wwade@users.noreply.github.com>
2021-10-19 19:27:15 -07:00
Tejal Desai 3b42fe45ea
chore: add release workflow on pr (#1785)
* chore: add release workflow on pr

* remove linux/s390x

* use keys

* set up platforms

* cancel

* update keys

* add secrets to env

* All platforms added for kaniko

Co-authored-by: Kun-Lu <kun.lu@ibm.com>

* echi

* add mt 1300, remove push

* Remove

* final change

* break executor and executor-slim

Co-authored-by: Kun-Lu <kun.lu@ibm.com>
2021-10-19 18:58:02 -07:00
Tejal Desai b873088c4a
remove ppc64le (#1784) 2021-10-19 13:10:55 -07:00
Tejal Desai 1c705f3541
bring them back (#1783) 2021-10-19 13:01:40 -07:00
Tejal Desai 4e8aae7c06
Revert ppce4 and other unintentional changes (#1781)
* Revert "fix dockefiles for deploy"

This reverts commit 63613adb82.

* revert unintentional test changes
2021-10-19 12:40:14 -07:00
Tejal Desai cf4822c31c
Run docker_credentials_gcr in warmer (#1780)
* run docker_credentials_gcr in warmer

* fix tests

* fix dockerfiles

* fix boilerplate

* mend

* fix

* another lint
2021-10-19 12:25:42 -07:00
Tejal Desai 21bb75717c
fix dockefiles for deploy gcr binsry (#1776) 2021-10-19 02:16:40 -07:00
Tejal Desai 779d224697
fix dockefiles for deploy (#1775) 2021-10-19 02:01:53 -07:00
Tejal Desai 63788dba63
fix dockefiles for deploy (#1774) 2021-10-19 01:50:44 -07:00
Tejal Desai a67ba0af65
fix dockefiles for deploy (#1773) 2021-10-19 01:30:35 -07:00
Tejal Desai a4daeb2cd7
chore: fix release pipeline (#1772) 2021-10-19 01:15:50 -07:00
Tejal Desai a65f63448f
Update RELEASE.md 2021-10-19 01:09:02 -07:00
Tejal Desai 32923d109f
Update release.yaml 2021-10-19 01:02:20 -07:00
Tejal Desai 13ea7d8292
release: v1.7.0 (#1771)
* release: v1.7.0

* add self serve instructions:

* more instructions

* Update CHANGELOG.md
2021-10-19 00:57:15 -07:00
Janosch Maier 46e01340c2
Remove tarball.WithCompressedCaching flag to resolve OOM Killed error (#1722)
* Remove tarball.WithCompressedCaching flag to resolve OOM Killed error

Large images cannot be build as the kaniko container will be killed due to an OOM error. Removing the tarball compression drastically reduces the memory required to push large image layers. Fixes #1680

This change may increase the build time for smaller images. Therefore a command line option to trigger the compression or a more intelligent behaviour may be useful.

* Add new command line flag to toggle compressed caching

* Add unittest for build with --compressed-caching command line flag set to false
2021-10-19 00:14:06 -07:00
Tejal Desai 822f72922a
diable on push to master (#1770) 2021-10-19 00:10:37 -07:00
Tejal Desai badd66506d
Add s390x support to docker images (#1769)
1. add s390x support to docker images `executor`, `executor(slim)`,
   `executor(debug)` and `warmer`. Fixes #1462 and #1665.

2. Address the building issue of dependency `docker-credential-gcr`
   in Dockerfiles. This issue was introduced when recent commits
   in `docker-credential-gcr` removed the Makefile.

Signed-off-by: Kun-Lu <kun.lu@ibm.com>

Co-authored-by: Kun-Lu <kun.lu@ibm.com>
2021-10-19 00:01:47 -07:00