Merge pull request #5 from xairy/master
Force container creation in tools/kernel-factory/bootstrap.sh
This commit is contained in:
commit
23f907b0f8
@ -1,9 +1,10 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh -eux
|
||||||
mkdir output
|
mkdir -p output
|
||||||
echo > output/kernels.toml
|
echo > output/kernels.toml
|
||||||
find | grep Docker | sed 's/Dockerfile//' | while read DOCKER; do
|
find | grep Docker | sed 's/Dockerfile//' | while read DOCKER; do
|
||||||
CONTAINER_NAME=$(echo $DOCKER | sed -e 's;/;;g' -e 's;\.;;g' -e 's;\(.*\);\L\1;')
|
CONTAINER_NAME=$(echo $DOCKER | sed -e 's;/;;g' -e 's;\.;;g' -e 's;\(.*\);\L\1;')
|
||||||
docker build -t ${CONTAINER_NAME} ${DOCKER}
|
docker build -t ${CONTAINER_NAME} ${DOCKER}
|
||||||
|
docker run ${CONTAINER_NAME} bash -c 'ls /boot'
|
||||||
CONTAINER_ID=$(docker ps -a | grep ${CONTAINER_NAME} | awk '{print $1}' | head -n 1)
|
CONTAINER_ID=$(docker ps -a | grep ${CONTAINER_NAME} | awk '{print $1}' | head -n 1)
|
||||||
docker cp ${CONTAINER_ID}:/boot/. output/
|
docker cp ${CONTAINER_ID}:/boot/. output/
|
||||||
DISTRO_NAME=$(echo $DOCKER | cut -d '/' -f 2)
|
DISTRO_NAME=$(echo $DOCKER | cut -d '/' -f 2)
|
||||||
|
Loading…
Reference in New Issue
Block a user