Created
September 19, 2014 14:18
-
-
Save kikicarbonell/f3873c35732247e9bb5c to your computer and use it in GitHub Desktop.
deis-cloud-config
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#cloud-config | |
hostname: deis-server2 | |
users: | |
- name: devops | |
passwd: $6$rounds=4096$z3E4YVD5Jq$VmaIx64Ab2pS6I0lZKMWrsvDDcQ8tv2.c1.EfDh9W2haEvzFjeKhYg2wu7ZZEttwNFBs9QUvrQxvYORLiR/qV. #devops | |
groups: | |
- sudo | |
- docker | |
coreos: | |
etcd: | |
discovery: http://172.23.0.42:4001/v2/keys/deisserver235ff4bd0501d7d49a920e526b119cbf6201 | |
addr: 172.23.10.105:4001 | |
peer-addr: 172.23.10.105:7001 | |
fleet: | |
public-ip: 172.23.10.105 | |
metadata: provider=baremetal-vc.datys.cu | |
units: | |
- name: etcd.service | |
command: start | |
- name: fleet.service | |
command: start | |
- name: docker.service | |
command: restart | |
- name: stop-update-engine.service | |
command: start | |
content: | | |
[Unit] | |
Description=stop update-engine | |
[Service] | |
Type=oneshot | |
ExecStart=/usr/bin/systemctl stop update-engine.service | |
ExecStartPost=/usr/bin/systemctl mask update-engine.service | |
write_files: | |
#cloud-config | |
- path: /etc/environment | |
permissions: 0644 | |
content: | | |
COREOS_PUBLIC_IPV4=172.23.10.105 | |
COREOS_PRIVATE_IPV4=172.23.10.105 | |
- path: /etc/systemd/system/update-engine.service.d/proxy.conf | |
content: | | |
[Service] | |
Environment=ALL_PROXY=http://172.23.1.0:3128 | |
- path: /etc/resolv.conf | |
permissions: 0644 | |
owner: root | |
content: | | |
nameserver 172.23.1.0 | |
- path: /etc/resolv.conf | |
permissions: 0644 | |
owner: root | |
content: | | |
nameserver 172.23.1.0 | |
- path: /etc/deis-release | |
content: | | |
DEIS_RELEASE=latest | |
#- path: /etc/motd | |
# content: | | |
# " \e[31m* * \e[34m* \e[32m***** \e[39mddddd eeeeeee iiiiiii ssss\n\e[31m* * \e[34m* * \e[32m* * \e[39md d e e i $ | |
- path: /etc/profile.d/nse-function.sh | |
permissions: 0755 | |
content: | | |
function nse() { | |
sudo nsenter --pid --uts --mount --ipc --net --target $(docker inspect --format="{{ .State.Pid }}" $1) | |
} | |
- path: /run/deis/bin/get_image | |
permissions: 0755 | |
content: | | |
#!/bin/bash | |
# usage: get_image <component_path> | |
IMAGE=`etcdctl get $1/image 2>/dev/null` | |
# if no image was set in etcd, we use the default plus the release string | |
if [ $? -ne 0 ]; then | |
RELEASE=`etcdctl get /deis/release 2>/dev/null` | |
# if no release was set in etcd, use the default provisioned with the server | |
if [ $? -ne 0 ]; then | |
source /etc/deis-release | |
RELEASE=$DEIS_RELEASE | |
fi | |
IMAGE=$1:$RELEASE | |
fi | |
# remove leading slash | |
echo ${IMAGE#/} | |
ssh_authorized_keys: | |
- ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDjyb6OxPc1o7bl9Fs59RFA59AekCFtg7/ruZlE9AYM+Vs6y8ht2tWN90bmzVaWhe6eqsQYxG+VNTP1m54t2Kpx2s3LBGdwxVnFjFrlSKblPeWja89gWs9x+gTZDoZV2D/of3D25QQGTjWYlAyRImS5bO6yGpXHGx8X7uXgOLAVZ2NJry6Y17VREhWjwBKcJUhZbhMOAIU9VYCV9lRq6bszJm31NyyfLQA+CidoyvUB/68UqFP9ru//kZSsAEScnH6veQ9vKnobkynEKtshqjQLGTr8e86fjUh+b/VS++djiBIqjq9VThuGJfHXXEPtUXTVP0DuJAJ09+rZRiTt/g75 deis |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment