Closed micahlmartin closed 6 years ago
Hm, how did you create your landscape.yaml file? It looks like you filled in and renamed landscape_config.yaml, because there are some parts of the landscape_base.yaml file missing, including the "addons" section, which causes your error. After you filled in the landscape_config.yaml file, the landscape.yaml file should be automatically created when entering the docker container. It is a merge of landscape_base.yaml and landscape_config.yaml, including configurations from both files. You can also generate it manually from inside the docker container by calling the build_landscape_yaml.sh script (starting the docker container via docker_run.sh won't overwrite it if it already exists).
Here is the gist of my landscape_config.yaml
which was used to generate the landscape.yaml
https://gist.github.com/micahlmartin/5c8c77b3ee4c841ddf087ea69f565932
I managed to get past the issue. I think part of the problem is that if you run ./docker_run.sh
before modifying your landscape_config.yaml
file it doesn't set the environment variables up properly like what happens here:
https://github.com/gardener/landscape-setup/blob/master/init.sh#L58-L63
# set cloud variant
if [ -f $LANDSCAPE_CONFIG ]; then
export CLOUD_VARIANT="$(yaml2json < $LANDSCAPE_CONFIG | jq -r .cloud.variant)"
export LANDSCAPE_NAME="$(grep -m 1 -F "domain_name:" "$LANDSCAPE_CONFIG" | awk '{ print $2 }')"
else
echo "WARNING: $LANDSCAPE_CONFIG not found! Did you provide $LANDSCAPE_HOME/landscape_config.yaml so that it can be created?"
fi
The example landscape_config.yaml
exists when you clone the repository so the else
case essentially never happens.
Ah, yes, I've also had problems with some environment variables not being set properly when changing the landscape files after the docker container is already started. Maybe I should have a look at this some time.
@Diaphteiros perhaps it's just a matter of always running source ./init.sh
at the end of the build_landscape_yaml.sh
script?
@micahlmartin Hm, that is actually a nice idea. I've added it to my current pull request.
Here are the contents of my
landscape.yaml
filewhen I run
./deploy_kubify.sh
I get this error:Any idea what might be causing this?