-
Notifications
You must be signed in to change notification settings - Fork 19
Design cf-remote config #165
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
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,54 @@ | ||
| # Indempotent VM spawning config | ||
|
|
||
|
|
||
|
|
||
| ## Core concepts: | ||
|
|
||
| - Fully reproducible and sharable cfengine testing environment | ||
| - Should work for dev environment: support for package install and scripts | ||
| - Atomic config: either all vms created or none. No in-between states. | ||
| - Top-down run order | ||
|
Comment on lines
+9
to
+10
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Not sure what you mean by these 2 points. |
||
| - VMs bound to config that generated them. Should not manually interfer: VMs should not be destroyed manually and the config should not be modified while VMs are running. | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think it's desirable if you can edit the config and re-run cf-remote. It should detect what is missing and fix it (repair it). This is useful to for example add one more client. |
||
| - Should provide abstraction of provider (aws, vagrant, static) | ||
|
|
||
|
|
||
| ## Example: | ||
|
|
||
| ``` | ||
| machines: | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think we should work a bit more on this part. I don't like the name (machines) and I don't like that it mixes some quite different things. For AWS and vagrant it specifies how / what to spawn (spawn config), while in static there is just a list of hosts. |
||
| - ubuntu-vm: | ||
| provider: aws # if we want to force provider | ||
| count: 1 # ignore if provider is "static" | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
What does this mean? |
||
|
|
||
| aws: | ||
| image: ubuntu-24 | ||
|
|
||
| vagrant: | ||
| image: ubuntu/focal64 | ||
| memory: 1024 | ||
| cpus: 2 | ||
|
Comment on lines
+23
to
+29
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. So in this case |
||
|
|
||
| static: | ||
| hosts: [ ubuntu@8.8.8.8, ubuntu@1.1.1.1 ] | ||
|
Comment on lines
+31
to
+32
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Static means managing pre-existing machines with SSH? |
||
|
|
||
| packages: | ||
| - cfengine-master: | ||
| package: cfengine | ||
| version: master | ||
| bootstrap: myhub # myhub count must be 1 | ||
|
|
||
| - git-latest: | ||
| package: git | ||
| version: latest | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What does latest mean? |
||
|
|
||
| hubs: | ||
| - myhub: | ||
| from: ubuntu-vm | ||
| install: [ cfengine-master, git-latest ] | ||
| scripts: [ ./provision.sh ] | ||
|
|
||
| clients: | ||
| - myclient: | ||
| from: ubuntu-vm | ||
| install: [ cfengine-master ] | ||
| ``` | ||
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.