mirror of
https://github.com/openfaas/faas.git
synced 2025-06-09 16:56:47 +00:00
Consolidate deploy_stack.sh files
Currently there are multiple deploy_stack.sh files and the user has to select the version appropriate to the target architecture so that the correct images are deployed. Further, the armhf deploy script lacks the basic auth by default scripting that is in the x86_64 version. This change adds a case/select to deploy_stack.sh that will determine the hardware architecture and select the appropriate docker-compose file. The deploy_stack.armhf.sh is also changed, rather than deleted, so that existing references are still valid. Signed-off-by: Richard Gee <richard@technologee.co.uk>
This commit is contained in:
parent
334288b130
commit
a02e2d2aa2
@ -1,9 +1,3 @@
|
||||
#!/bin/sh
|
||||
|
||||
if ! [ -x "$(command -v docker)" ]; then
|
||||
echo 'Unable to find docker command, please install Docker (https://www.docker.com/) and retry' >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "Deploying stack"
|
||||
docker stack deploy func --compose-file docker-compose.armhf.yml
|
||||
sh ./deploy_stack.sh
|
||||
|
@ -49,6 +49,18 @@ else
|
||||
echo ""
|
||||
fi
|
||||
|
||||
echo "Deploying OpenFaaS core services"
|
||||
arch=$(uname -m)
|
||||
case "$arch" in
|
||||
|
||||
docker stack deploy func --compose-file docker-compose.yml
|
||||
"armv7l") echo "Deploying OpenFaaS core services for ARM"
|
||||
composefile="docker-compose.armhf.yml"
|
||||
;;
|
||||
"aarch64") echo "Deploying OpenFaaS core services for ARM64"
|
||||
composefile="docker-compose.arm64.yml"
|
||||
;;
|
||||
*) echo "Deploying OpenFaaS core services"
|
||||
composefile="docker-compose.yml"
|
||||
;;
|
||||
esac
|
||||
|
||||
docker stack deploy func --compose-file $composefile
|
||||
|
Loading…
x
Reference in New Issue
Block a user