update repository references and improve script handling
This commit is contained in:
18
base_docker_images/build_local.sh
Executable file
18
base_docker_images/build_local.sh
Executable file
@@ -0,0 +1,18 @@
|
||||
#!/bin/bash
|
||||
|
||||
DOCKER_USER="mesteriis"
|
||||
DOCKER_REPO="hassio"
|
||||
|
||||
find . -name 'Dockerfile' | while read dockerfile; do
|
||||
dir=$(dirname "$dockerfile")
|
||||
tag_name=$(echo "$dir" | sed 's|^\./||' | tr '/' '-' | tr -d '[:space:]' | tr '[:upper:]' '[:lower:]')
|
||||
git_sha=$(git rev-parse --short HEAD)
|
||||
|
||||
base_tag="${DOCKER_USER}/${DOCKER_REPO}-${tag_name}"
|
||||
command="docker build -t ${base_tag}:${git_sha} -t ${base_tag}:latest $dir"
|
||||
echo $command
|
||||
docker build -t ${base_tag}:${git_sha} -t ${base_tag}:latest $dir
|
||||
docker push ${base_tag}:${git_sha}
|
||||
docker push ${base_tag}:latest
|
||||
|
||||
done
|
||||
3
base_docker_images/python/3.11/Makefile
Normal file
3
base_docker_images/python/3.11/Makefile
Normal file
@@ -0,0 +1,3 @@
|
||||
build:
|
||||
@echo "Building base docker images..."
|
||||
@docker build Dockerfile_python -t base_python:latest
|
||||
Reference in New Issue
Block a user