27 lines
435 B
Bash
Executable File
27 lines
435 B
Bash
Executable File
#!/bin/bash
|
|
|
|
check_installed() {
|
|
if ! [ -x "$(command -v $1)" ]; then
|
|
echo "Error: $1 is not installed." >&2
|
|
exit 1
|
|
fi
|
|
}
|
|
|
|
check_installed docker-compose
|
|
check_installed yarn
|
|
check_installed mvn
|
|
|
|
docker-compose down
|
|
|
|
# Generate Nuxt.js static website
|
|
pushd frontend || exit 1
|
|
yarn run generate
|
|
popd || exit 1
|
|
|
|
# Generate fat jar
|
|
pushd api || exit 1
|
|
mvn clean package
|
|
popd || exit 1
|
|
|
|
docker-compose up -d --build
|