diff --git a/.travis.yml b/.travis.yml index ffa2bbc..bf3e5fb 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,9 +3,13 @@ services: docker env: - VERSION=3.11 + - VERSION=3.11 ARCH=i386 - VERSION=3.0 + - VERSION=3.0 ARCH=i386 - VERSION=2.2 + - VERSION=2.2 ARCH=i386 - VERSION=2.1 + - VERSION=2.1 ARCH=i386 install: - git clone https://github.com/docker-library/official-images.git ~/official-images @@ -14,6 +18,12 @@ before_script: - env | sort - cd "$VERSION" - image="cassandra:$VERSION" + - | + if [ -n "$ARCH" ]; then + from="$(awk '$1 == toupper("FROM") { print $2 }' Dockerfile)" + docker pull "$ARCH/$from" + docker tag "$ARCH/$from" "$from" + fi script: - travis_retry docker build -t "$image" . diff --git a/generate-stackbrew-library.sh b/generate-stackbrew-library.sh index 5d987b5..9df1e4a 100755 --- a/generate-stackbrew-library.sh +++ b/generate-stackbrew-library.sh @@ -60,9 +60,14 @@ for version in "${versions[@]}"; do fi versionAliases+=( ${aliases[$version]:-} ) + # $ wget -qO- 'https://dl.bintray.com/apache/cassandra/dists/311x/Release' | grep '^Architectures:' + # Architectures: i386 amd64 + arches='amd64 i386' + echo cat <<-EOE Tags: $(join ', ' "${versionAliases[@]}") + Architectures: $(join ', ' $arches) GitCommit: $commit Directory: $version EOE diff --git a/update.sh b/update.sh index 6af190d..3032fd9 100755 --- a/update.sh +++ b/update.sh @@ -21,6 +21,7 @@ for version in "${versions[@]}"; do sed 's/%%CASSANDRA_DIST%%/'$dist'/g; s/%%CASSANDRA_VERSION%%/'$fullVersion'/g' Dockerfile.template > "$version/Dockerfile" ) + travisEnv='\n - VERSION='"$version ARCH=i386$travisEnv" travisEnv='\n - VERSION='"$version$travisEnv" done