-
Notifications
You must be signed in to change notification settings - Fork 6.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[jjo] add DIND support to contrib/ #3468
Conversation
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: If they are not already assigned, you can assign the PR to them by writing The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
af5ee24
to
bd6942e
Compare
That's awesome, Thank you ! How complex would be to do the same but on an existing kubernetes cluster instead of using docker directly? Create 'node-pod' with the kubernetes API (statefullset?), deploy on kubespray on tthose node-pod via kubernetes job? |
@ant31 wrote:
KINK via kubespray ? |
yes, KINK, I like the name :)
Yes, sure |
- rsyslog | ||
- ssh | ||
|
||
- name: Create ubuntu user |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can this user be configurable and then default to ubuntu?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ditto above(ish), IMO would also require adding variables to select docker "distro"
image for container nodes -- technically easy to add, practically would need better
care on the testing side, to be able to assert this distro "generalization".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
BTW thanks for the suggestion, will give it a try w/Debian to see how it'd look
3735a82
to
99c402e
Compare
@mattymo: added selectable |
e9ae59b
to
f8be0ed
Compare
contrib/dind/README.md
Outdated
(as set in `group_vars/all/all.yaml`), and docker settings. | ||
|
||
~~~ | ||
cat > custom.yaml << EOF |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you just commit this file and eventually comment everything ?
It's better to reduce to the strict minimum actions required
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added as contrib/dind/kubespray-dind.yaml
instead (don't
want to pollute kubespray repo root with such file), also added
fedora support (tested to the extent of kubespray deployment finishing ok), PTAL,
FYI latest update has all the changes I wanted in for this PR, |
819578b
to
eeff9ca
Compare
@ant31 passing all tests as run from
|
4d6f29f
to
5a73680
Compare
- add contrib/dind with ansible playbook to create "node" containers, and setup them to mimic host nodes as much as possible (using Ubuntu images), see contrib/dind/README.md - nodes' /etc/hosts editing via `blockinfile` and `lineinfile` need `unsafe_writes: yes` because /etc/hosts are mounted by docker, and thus can't be handled atomically (modify copy + rename)
- add kubespray-dind.yaml (former custom.yaml at README.md) - rework README.md as per above - use some YAML power to share distros' commonality - add fedora support
- create unique /etc/machine-id in each docker node, used as seed for e.g. weave mac addresses - with above, now netchecker 100% passes WoHooOO! 🎉 🎉 🎉 - updated README.md output from (1.12.1, verified netcheck)
…y facts, also verified netcheck Ok \o/
9a4664f
to
cf05ea5
Compare
ci check this |
Thanks ! I think it would worth the mention it on the repo README, probably a Contrib section with the list of thing you can find inside (azure, terraform, dind...) |
add contrib/dind with ansible playbook to create "node" containers,
and setup them to mimic host nodes as much as possible see
contrib/dind/README.md
supported node_distro's (docker images):
debian
,ubuntu
,centos
,fedora
kubespray core changes: nodes'
/etc/hosts
editing viablockinfile
and
lineinfile
needunsafe_writes: yes
because/etc/hosts
is bind-mounted by docker, thus can't be handled atomically via
copy + modify + rename