Commit Graph

225 Commits

Author SHA1 Message Date
Kubernetes Prow Robot 95e9cbf8ab
Merge pull request #10566 from rifelpet/fs-err
Fix file not found error detection in fs://
2021-01-12 22:42:35 -08:00
Peter Rifel 0df5f6c24d
Fix file not found error detection in fs:// 2021-01-12 20:57:33 -06:00
Justin Santa Barbara 78b139465c Refactor and centralize distribution logic
Use of a struct makes it more sustainable, centralizing into the
distribution package makes it simpler to follow.
2021-01-05 11:50:23 -05:00
Justin SB b17e44b709 Recognize ubuntu 20.10
Teach nodeup about ubuntu 20.10, including the unusual
/etc/resolv.conf configuration.
2021-01-05 10:53:40 -05:00
Kenji Kaneda a61caea8d2 Add Azure support
This commit contains all changes required to support Azure
(https://github.com/kubernetes/kops/issues/3957).
2020-12-21 08:27:54 -08:00
Justin SB 7d9ff3ba96 Refactor MirroredAsset into mirrors package
This means we can use MirroredAsset for nodeup without circular
dependencies.  Also removes a duplicate constant that was declared
twice.
2020-12-19 18:39:09 -05:00
Kenji Kaneda 40c944aa5c Fix a typo in an error message returned from buildAzureBlobPath
invalid Azure Blob schem -> invalid Azure Blob scheme
2020-11-23 08:16:39 -08:00
Kenji Kaneda 4555c0b2df Add support of Azure Blob storage to VFS
The schema is "azureblob".

azureClient provides two ways to set up credential. One approach is to
use an account key stored in env var. This approach is used when
accessing Blob from kops CLI. The second approach is to retrieve
credentials from Instance Metadata Service. This works only when
azureClient is created on a VM that has sufficient privilege to access
a specified blob. This approach is used from nodeup, etcd-manager,
etc.
2020-11-19 10:47:03 -08:00
Jesse Haka 67d69f16a9 allow reauth for openstack client 2020-10-30 08:57:49 +02:00
Ole Markus With f6ce70e5c3 Minor fixes to swiftfs.go 2020-10-08 20:32:29 +02:00
Ciprian Hacman 0c6f1c733c Use all kops mirrors to determine artifacts hashes 2020-09-18 09:44:37 +03:00
Kubernetes Prow Robot a5fc8895dc
Merge pull request #9857 from hakman/detect-aws-region
Detect AWS region for S3 inside containers
2020-09-09 23:17:44 -07:00
John Gardiner Myers 1e92c7740c Map ENOENT to ErrNotExist in FSPath 2020-09-05 21:46:57 -07:00
Ciprian Hacman 32e6da7576 Detect AWS region for S3 inside containers 2020-09-02 06:41:12 +03:00
Kubernetes Prow Robot fc66e0161e
Merge pull request #9836 from justinsb/openstack_reauth
Always use OpenStack Swift reauthentication
2020-08-31 00:40:20 -07:00
Justin SB c63ce4b5ab Implement setter by reflection
This means we no longer have to individually hard-code the `kops set`
fields, however we use the "language" we're now demonstrated.

We add tests to ensure we have parity with our existing (hard-coded)
setter logic.
2020-08-30 09:59:52 -04:00
Justin SB d4480e4721 Always use OpenStack Swift reauthentication
If we were using credentials from env vars, we would not do
reauthentication with Swift.
2020-08-29 08:25:59 -04:00
Ciprian Hacman 0da3980865 Use /etc/os-release to identify the distribution 2020-08-17 07:25:44 +03:00
Ciprian Hacman e29b84da01 Add tests for distributions 2020-08-17 07:25:43 +03:00
Ciprian Hacman 22ec1512dc Use numbers for distribution names 2020-08-17 07:25:43 +03:00
Ciprian Hacman 3825f657cc Use const for architectures and distributions 2020-08-17 07:25:43 +03:00
Ciprian Hacman 795373a499 Remove unused function 2020-08-17 07:25:43 +03:00
Ciprian Hacman 3f43d047dd Remove confusing comment 2020-08-17 07:25:43 +03:00
Ciprian Hacman e68ee80a93 Move and rename the "distros" package 2020-08-17 07:25:43 +03:00
Peter Rifel 4d9f0128a3
Upgrade to klog2
This splits up the kubernetes 1.19 PR to make it easier to keep up to date until we get it sorted out.
2020-08-16 20:56:48 -05:00
Ole Markus With a708a96c05 Adds support for using OS application credentials
Application credentials allows you to export a purpose-specific set of
credentials for a user instead of exposing user login credentials.
Especially useful when using LDAP or similar for Openstack users.
Also lets you rotate credentials more easily since multiple application
credentials can be provisioned per user.

Update pkg/model/bootstrapscript.go

Co-authored-by: Ciprian Hacman <ciprianhacman@gmail.com>
2020-08-07 14:26:47 +02:00
Ole Markus With d1479fb666 Add support for reading openstack metadata in vfs 2020-08-04 08:22:00 +02:00
John Gardiner Myers fed5587d77 Improve locking in memfs 2020-07-19 16:01:47 -07:00
Kubernetes Prow Robot aa7b67124f
Merge pull request #9535 from hakman/env-arch-amd64
Force single arch support via env var
2020-07-09 09:00:31 -07:00
Ciprian Hacman 3c84d83d37 Address review comments 2020-07-09 17:07:37 +03:00
Zhou Hao d6695b822f Add err judgment to os.RemoveAll
Signed-off-by: Zhou Hao <zhouhao@cn.fujitsu.com>
2020-07-09 16:48:35 +08:00
Zhou Hao 34931ed930 Add err judgment to ioutil.TempDir
Signed-off-by: Zhou Hao <zhouhao@cn.fujitsu.com>
2020-07-09 16:45:12 +08:00
Ciprian Hacman 9b77f372f1 Fix typo in function name 2020-07-09 10:45:50 +03:00
Ciprian Hacman 1f296e58f6 Force AMD64 only support via env var 2020-07-09 09:31:54 +03:00
Li Zhijian c3fc293ede cleanup tempfiles for fs_test
Signed-off-by: Li Zhijian <lizhijian@cn.fujitsu.com>
2020-07-02 10:09:34 +08:00
Xiaoyu Zhong 98c35cd220 Rename accessKeyId to accessKeyID 2020-06-22 09:32:20 +08:00
Kubernetes Prow Robot 8b371acef0
Merge pull request #9094 from olemarkus/vault-vfs
Implement VFS for vault
2020-06-20 12:02:39 -07:00
Ciprian Hacman a49879c4bc ARM64 support - Add architecture 2020-06-19 04:42:11 +03:00
Ole Markus With acaa1e1dfc Implement VFS for vault 2020-06-18 13:02:37 +02:00
ZouYu 2fc52ec6be fix some go-lint warning
Signed-off-by: ZouYu <zouy.fnst@cn.fujitsu.com>
2020-06-09 08:52:50 +08:00
Ciprian Hacman 654a0d2d8a Detect supported architecture during node setup 2020-06-03 17:23:59 +03:00
Kubernetes Prow Robot 5e27f74dd8
Merge pull request #9228 from justinsb/paginate_delete_all_versions
S3 DeleteAllVersions: use pagination
2020-05-31 15:59:54 -07:00
Justin SB 319ddcc333 S3 DeleteAllVersions: use pagination
This way we're not limited to one page of versions.  This is likely a
purely theoretical concern, at least as we're using it today.
2020-05-31 18:21:05 -04:00
Justin SB 7d7b8969ea Use AWS SDK to fetch metadata
Previously the EC2 metadata service was straightforward HTTP, but IMDS
v2 now requires managing a session token (and is more secure for it).

We now use the AWS SDK when retrieving metadata; it automatically
supports IMDS v2.
2020-05-31 17:23:01 -04:00
Ciprian Hacman d54aadc89c Fix nits for removal of S3 file versions 2020-05-28 06:50:32 +03:00
Kubernetes Prow Robot 92f8e22002
Merge pull request #9174 from johngmyers/remove-vfsscan
Remove unused VFSScan
2020-05-27 09:24:48 -07:00
Ciprian Hacman 9675692b84 Implement RemoveAll() for S3 paths 2020-05-25 07:46:32 +03:00
John Gardiner Myers 62ebbc5a5d Remove unused VFSScan 2020-05-24 21:27:28 -07:00
Ciprian Hacman b565122875 Remove delete markers also from S3 bucket 2020-05-24 17:42:02 +03:00
Ciprian Hacman a48ccfa06c Return warning instead of error to hide issues during cluster teardown 2020-05-24 15:20:20 +03:00