diff --git a/.cc/{{cookiecutter.__demo_slug}}/containers/{{cookiecutter.__demo_slug}}/.devcontainer/postCreate.sh.jinja b/.cc/{{cookiecutter.__demo_slug}}/containers/{{cookiecutter.__demo_slug}}/.devcontainer/postCreate.sh.jinja index f6d190b..c6d1001 100644 --- a/.cc/{{cookiecutter.__demo_slug}}/containers/{{cookiecutter.__demo_slug}}/.devcontainer/postCreate.sh.jinja +++ b/.cc/{{cookiecutter.__demo_slug}}/containers/{{cookiecutter.__demo_slug}}/.devcontainer/postCreate.sh.jinja @@ -14,8 +14,10 @@ ardl get eos --image-type cEOS --version ${CEOS_LAB_VERSION} --import-docker # init demo dir as Git repo if requested for this demo env if ${GIT_INIT}; then cd ${CONTAINERWSF} - git config --global --add safe.directory . git init + git config --global --add safe.directory ${PWD} + if [ -z "$(git config user.name)" ]; then git config user.name "Lab User"; fi + if [ -z "$(git config user.email)" ]; then git config user.email user@one-click.lab; fi git add . git commit -m "git init" fi diff --git a/containers/avd-avd-extended-workshop--part-1/.devcontainer/postCreate.sh b/containers/avd-avd-extended-workshop--part-1/.devcontainer/postCreate.sh index 0ab3cf5..009ba71 100644 --- a/containers/avd-avd-extended-workshop--part-1/.devcontainer/postCreate.sh +++ b/containers/avd-avd-extended-workshop--part-1/.devcontainer/postCreate.sh @@ -14,8 +14,10 @@ ardl get eos --image-type cEOS --version ${CEOS_LAB_VERSION} --import-docker # init demo dir as Git repo if requested for this demo env if ${GIT_INIT}; then cd ${CONTAINERWSF} - git config --global --add safe.directory . git init + git config --global --add safe.directory ${PWD} + if [ -z "$(git config user.name)" ]; then git config user.name "Lab User"; fi + if [ -z "$(git config user.email)" ]; then git config user.email user@one-click.lab; fi git add . git commit -m "git init" fi diff --git a/containers/clab-build-containerlab-with-ceos/.devcontainer/postCreate.sh b/containers/clab-build-containerlab-with-ceos/.devcontainer/postCreate.sh index 11ceb3a..2df491e 100644 --- a/containers/clab-build-containerlab-with-ceos/.devcontainer/postCreate.sh +++ b/containers/clab-build-containerlab-with-ceos/.devcontainer/postCreate.sh @@ -12,8 +12,10 @@ ardl get eos --image-type cEOS --version ${CEOS_LAB_VERSION} --import-docker # init demo dir as Git repo if requested for this demo env if ${GIT_INIT}; then cd ${CONTAINERWSF} - git config --global --add safe.directory . git init + git config --global --add safe.directory ${PWD} + if [ -z "$(git config user.name)" ]; then git config user.name "Lab User"; fi + if [ -z "$(git config user.email)" ]; then git config user.email user@one-click.lab; fi git add . git commit -m "git init" fi diff --git a/containers/cvaas-cvaas-and-avd-demo--evpn-aa/.devcontainer/postCreate.sh b/containers/cvaas-cvaas-and-avd-demo--evpn-aa/.devcontainer/postCreate.sh index 0ab3cf5..009ba71 100644 --- a/containers/cvaas-cvaas-and-avd-demo--evpn-aa/.devcontainer/postCreate.sh +++ b/containers/cvaas-cvaas-and-avd-demo--evpn-aa/.devcontainer/postCreate.sh @@ -14,8 +14,10 @@ ardl get eos --image-type cEOS --version ${CEOS_LAB_VERSION} --import-docker # init demo dir as Git repo if requested for this demo env if ${GIT_INIT}; then cd ${CONTAINERWSF} - git config --global --add safe.directory . git init + git config --global --add safe.directory ${PWD} + if [ -z "$(git config user.name)" ]; then git config user.name "Lab User"; fi + if [ -z "$(git config user.email)" ]; then git config user.email user@one-click.lab; fi git add . git commit -m "git init" fi