...
 
Commits (3)
......@@ -12,7 +12,9 @@ Note: this needs to be done by Greenhost employees at the moment.
relevant user, then go to "User settings", tab "API keys"); a new one will be
generated automatically when the VPS is stopped and started from Cosmos2.
5. Reboot the VPSs after changing the `api_enabled` property, and also if you
did something at step 4.
did something at step 4. Be careful: the new api key that is created for the
machine is coupled to the user as which you are logged in when you restart
the VPS!
## Install driver and provisioner
......
......@@ -85,7 +85,7 @@ ghostAction() {
attach) ;&
detach) ;;
*)
output "{\"status\": \"Unsupported action\"}"
output "Unsupported action"
exit 0
esac
local url="${server}/api/v2/disks/$diskImage/actions"
......@@ -152,7 +152,7 @@ domount() {
device="/dev/xvd${diskLetter}1"
debug "device: $device"
# Use the `blkid` program to scan the device for an existing filesystem.
existingFileSystem=$(blkid "$device")
existingFileSystem=$(lsblk -n -o FSTYPE "$device")
debug "blkid: $existingFileSystem"
if [[ -z "$existingFileSystem" ]]
then
......@@ -167,7 +167,7 @@ domount() {
# Mount the virtual block device at the given mount point.
mount "$device" "$mountPath" >/dev/null 2>&1
output "{\"status\":\"Success\"}"
output "Success"
exit 0
}
......@@ -181,7 +181,7 @@ unmount() {
# enough information to do so. Instead, we do a just-in-time detach when
# the disk is attached later on.
output "{\"status\":\"Success\"}"
output "Success"
exit 0
}
......@@ -191,7 +191,7 @@ op=$1
if [[ "$op" = "init" ]]
then
debug "init $@"
output "{\"status\":\"Success\",\"capabilities\":{\"attach\":false}}"
echo "{\"status\":\"Success\",\"capabilities\":{\"attach\":false}}" >&1
exit 0
fi
......@@ -206,6 +206,6 @@ case "$op" in
;;
*)
debug "not supported: $op $*"
output "{\"status\":\"Not supported\"}"
echo "{\"status\":\"Not supported\"}" >&1
exit 0
esac
......@@ -2,7 +2,7 @@ provisioner:
image:
repository: "docker.greenhost.net/open/kubernetes-ghost/provisioner"
tag: "0.1.0"
imagePullPolicy: "Always"
pullPolicy: "Always"
cosmos_api_url: "https://service.greenhost.net/api/v2"
cosmos_location: "ams1"
......@@ -10,7 +10,7 @@ driver:
image:
repository: "docker.greenhost.net/open/kubernetes-ghost/driver"
tag: "0.1.0"
imagePullPolicy: "Always"
pullPolicy: "Always"
# Make this storage class the default, so persistent volume claims that do not
# specify a class are served by this provisioner.
......