About Me
CTO/CO-FOUNDER
systems engineer
@brandonphilips
github.com/philips
What is CoreOS?
What is CoreOS?
What is CoreOS?
Why build CoreOS?
reduce API contracts
minimal
kernel
systemd
etcd
ssh
docker
python
java
nginx
mysql
openssl
app
distrodistrodistrodistrodistrodistrodistr
python
java
nginx
mysql
openssl
app
distrodistrodistrodistrodistrodistrodistr
kernel
systemd
etcd
ssh
docker
python
openssl-A
app1
distrodistrodistrodistrodistrodistrodistr java
openssl-B
app2
java
openssl-B
app3
kernel
systemd
etcd
ssh
docker
CoreOS
python
openssl-A
app1
distrodistrodistrodistrodistrodistrodistr java
openssl-B
app2
java
openssl-B
app3
CoreOS
container
distrodistrodistrodistrodistrodistrodistr
container
container
https://github.com/philips/hacks
folder: system-api-tutorial
APIs
Linux syscalls
API
manual
updates
automatic
updates
automatic
updates
atomic with rollback
auto updates
omaha
API
run and isolate apps
containers
http
registry
image fetch
pid ns
isolated pid 1
user ns
isolated uid 0
network ns
isolated netdev
mount ns
isolated /
cgroups
manage resources
cgroups
count resources
cgroups
limit resources
namespaces
API
cgroups
API
docker engine
REST
API
dbus
API
machines and clusters
configuration
get into the cluster
machine conf
#cloud-config
ssh_authorized_keys:
- ssh-rsa AAAAB3NzaC1yc2E…
coreos:
etcd:
discovery: https://discovery.etcd.io/ba09c
units:
- name: etcd2.service
command: start
- name: fleet.service
command: start
#cloud-config
ssh_authorized_keys:
- ssh-rsa AAAAB3NzaC1yc2E…
coreos:
etcd:
discovery: https://discovery.etcd.io/ba09c
units:
- name: etcd2.service
command: start
- name: fleet.service
command: start
#cloud-config
ssh_authorized_keys:
- ssh-rsa AAAAB3NzaC1yc2E…
coreos:
etcd:
discovery: https://discovery.etcd.io/ba09c
units:
- name: etcd2.service
command: start
- name: fleet.service
command: start
REST
hypercalls
filesystems
API
what is running
cluster conf
k8s, discoverd, confd
services
what should run
cluster conf
locksmith
coordination
fleet, k8s
scheduling
etcd
API
etcd
/etc
distributed
Available
Available
Available
Unavailable
Available
Leader
Follower
Leader
Follower
Available
Leader
Follower
Temporarily Unavailable
Leader
Follower
Available
http+json
API
getting work to servers
scheduling
You
Scheduler API
Scheduler
Machine(s)
$ kubectl run-container
my-nginx --image=nginx
--replicas=1 --port=80
$ kubectl get pods
POD IP
my-nginx-97wt8 10.2.29.4
http+json
API
$ cat nginx.service
[Service]
ExecStart=/usr/bin/rkt 
docker://nginx
$ fleetctl start nginx.service
Job nginx.service launched on
e1cd2bcd.../172.17.8.101
http+json
API
while true {
todo = diff(desState, curState)
schedule(todo)
}
while true {
todo = diff(desState, curState)
schedule(todo)
}
while true {
todo = diff(desState, curState)
schedule(todo)
}
while true {
todo = diff(desState, curState)
schedule(todo)
}
the future
CoreOS @ gluecon 2015

CoreOS @ gluecon 2015