Commit Graph

37 Commits

Author SHA1 Message Date
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
Ciprian Hacman d75042cc85 Remove unused Tags from NodeUp 2020-08-12 18:35:26 +03:00
John Gardiner Myers 852e70f54d Don't require nodeup tasks to have SetName() 2020-06-08 08:42:42 -07:00
John Gardiner Myers 8b9145f6c4 Create nodetasks.IssueCert() 2020-06-05 08:00:38 -07:00
Kubernetes Prow Robot 6830cf6d44
Merge pull request #9065 from johngmyers/remove-distro
Remove support for CoreOS and Jessie
2020-05-27 23:22:01 -07:00
John Gardiner Myers 4e68ba9a5b Remove loader support for nodeup tasks not used in models 2020-05-23 22:01:12 -07:00
John Gardiner Myers 2d98e5609c Remove/fix more CoreOS references 2020-05-22 20:54:41 -07:00
Justin SB b6d41f3272
nodeup: Add some dependencies for Service
We handle service dependencies on BindMount and Archive tasks; this
avoids some false-positive warning messages.
2020-01-04 13:18:13 -05:00
mikesplain 9e55b8230a Update copyright notices
Also cleans some white spaces
2019-09-09 14:47:51 -04:00
Salvatore Mazzarino 5e9bec9b79 Check systemd path
Signed-off-by: Salvatore Mazzarino <dev@mazzarino.cz>
2019-08-23 12:00:08 +02:00
Justin SB 10a7f9afb0
Move NTP and misc package initialization to code
Paring down the nodeup portion of gobindata
2019-07-19 07:34:44 -04:00
Justin SB 3e33ac7682
Change code from glog to klog
We don't call klog.InitFlags yet, because that will cause a flag
redefinition error until we get everyone to stop using glog.  That
will happen when we update to k8s 1.13.
2019-05-06 12:54:51 -04:00
Justin SB 9bfa0cdd2a
Try using chattr to mark docker-runc as immutable
May be a workaround for CVE-2019-5736, is defense in depth in any case.
2019-02-20 22:26:44 -05:00
André Carvalho 2f273d6e35 nodeup: include underlying error in error message 2018-12-28 17:26:01 -02:00
Justin Santa Barbara 2faa68426f Docker installation from tar.gz
Ubuntu 18.04 doesn't have a package for docker 17.03, but we can still
support it by using the tar.gz package.

This could be a nice fallback for other operating systems in future,
and it might prove to be more reliable than the OS packages.

But start with supporting ubuntu 18.04 with older docker versions!
2018-07-24 21:58:54 -04:00
AdamDang e11f36309f
Typo fix in info message
Typo fix in info message
2018-04-02 22:02:40 +08:00
Rohith 153db84df1 Custom Manifests via Hooks
The present implementation of hooks only perform for docker exec, which isn't that flexible. This PR permits the user to greater customize systemd units on the instances

- cleaned up the manifest code, added tests and permit setting a section raw
- added the ability to filter hooks via master and node roles
- updated the documentation to reflect the changes
- cleaned up some of the vetting issues
2017-08-11 12:40:10 +01:00
Justin Santa Barbara cb8ea7e043 Use repeated flags for log-opt to docker
Also add tests for the expected format
2017-03-28 00:53:31 -04:00
Justin Santa Barbara 4006741a5d Update for new taints / labels names 2017-03-27 23:13:39 -04:00
Justin Santa Barbara bdf0d04b0a Merge pull request #2104 from justinsb/container_optimized_os
Initial Container-Optimized OS support
2017-03-27 10:21:39 -04:00
Justin Santa Barbara b9204e9911 Initial Container-Optimized OS support
Add initial support for google's container-optimized OS (available on
GCE).
2017-03-20 23:47:37 -04:00
Justin Santa Barbara 93ae440bab service task: consider changes to the systemd manifest itself
We do smart service restarting: we restart the service if a dependency
changed after the running service.  However, we were not considering the
service manifest itself in the calculation, which was an error.

The bug only exposed itself though when we downloaded and updated
docker, e.g. when running k8s 1.5 with a 1.4 image.  We would write the
env file early (no dependencies), then we would download docker and
install it, and then we would write the service manifest.  But if docker
had been started during this interval (e.g. by protokube), then we would
see that docker had been started after the dependencies (the env file),
and not restart it.  When we consider the manifest file also, things
work as intended.

Fix #1731
2017-03-11 02:26:44 -05:00
Justin Santa Barbara 1bacf8271e Initial (experimental) CoreOS support
* Detect CoreOS
* Move key manifests to code, to tolerate read-only mounts
* Misc refactorings so more code can be shared
* Change lots of ints to int32s in the models
* Run nodeup as a oneshot systemd service, rather than relying on
cloud-init behaviour which varies across distros
2017-02-11 13:57:30 -03:00
Justin Santa Barbara 8342208cc5 Build docker service in code, to cope with variations
The docker systemd manifest changes a lot between versions - build it in
code for sanity.
2017-01-10 15:22:09 -05:00
Zach Loafman 1f657990b3 Disable kubelet from starting until after volume mounts
* Change protokube to do `systemctl start kubelet` every sync round
** .. which takes a change to the systemd unit for protokube to mount in D-Bus
* Don't start kubelet in nodeup
2016-11-23 11:30:19 -08:00
Justin Santa Barbara d6f86ca968 A few tests for nodeup tasks 2016-10-18 21:19:09 -04:00
Zach Loafman 21c479d5b3 nodeup: Add docker.service dep to LoadImageTask
Tested with manual build and NODEUP_URL

Fixes #685, #686
2016-10-18 14:56:31 -07:00
chrislovecnm 8fa2aac99f fixing more headers 2016-10-15 19:20:56 -06:00
Justin Santa Barbara a47674d10c Redhat/CentOS fixes per code review
* Always read /etc/redhat-release (symlinked on CentOS)
* Make _rhel_family the tag name, not _centos_family
* Add comment about writing to "system" systemd area
2016-10-07 09:43:04 -04:00
Justin Santa Barbara d86390c172 CentOS7 initial experimental support 2016-10-06 23:23:30 -04:00
Justin Santa Barbara 9b7291ab24 A few nodeup cleanups
* Correctly identify user tasks as a dependency for services
* Cleaned up flag-walking
2016-08-16 10:10:44 -04:00
Justin Santa Barbara 09dd3002ff Make sure that we enable systemd services
We were previously just starting them, which works fine for the new
machine and machine termination case, but doesn't work when doing a
machine restart (e.g. init 6)

Issue #70
2016-07-06 23:04:51 -04:00
Justin Santa Barbara d427858477 Rename to kops
The upup tool is now called kops, and we have moved repos
2016-06-30 09:25:25 -04:00
Justin Santa Barbara 82f373cba0 nodeup: make sure tasks implement HasDependencies 2016-06-04 16:13:25 -04:00
Justin Santa Barbara 370727aa44 Support for persistent disks, users & symlinks
These are required to mount the master PD.  We use the kubernetes
safe-format-and-mount implementation.
2016-05-13 13:29:56 -04:00
Justin Santa Barbara d4c2cfaae7 Initial version of upup: cloudup & nodeup
* GCE support only
* Key and secret generation
* "Direct mode" makes API calls
* "Dry run mode" previews the changes
* Terraform output (though key generation not working for master ip)
* cloud-init output (though debian image does not ship with cloud-init)
2016-05-06 16:01:33 -04:00