4 Commits

Author SHA1 Message Date
Matthew Wild b98fdd49f4 build-docker.sh: Some small improvements for parameter handling 2016-03-11 17:37:41 +00:00
Matthew Wild c095ddd323 Dockerfile: chmod 755 the entrypoint, so we don't depend on the permissions of the build system, fixes #27 2016-03-11 15:51:35 +00:00
Matthew Wild 6d139045cf Merge pull request #28 from prosody/27-entrypoint.sh
Make `entrypoint.sh` executable
2016-03-09 11:13:37 +00:00
Lloyd Watkin b31d7c913e Make entrypoint.sh executable
Fixes #27
cc @mwild1
2016-03-09 08:52:23 +00:00
2 changed files with 7 additions and 6 deletions
+1
View File
@@ -34,6 +34,7 @@ RUN dpkg -i /tmp/prosody.deb \
&& perl -i -pe 'BEGIN{undef $/;} s/^log = {.*?^}$/log = {\n {levels = {min = "info"}, to = "console"};\n}/smg' /etc/prosody/prosody.cfg.lua
COPY ./entrypoint.sh /entrypoint.sh
RUN chmod 755 /entrypoint.sh
ENTRYPOINT ["/entrypoint.sh"]
EXPOSE 80 443 5222 5269 5347 5280 5281
+6 -6
View File
@@ -1,4 +1,4 @@
# /bin/bash
#!/bin/bash
if [[ -z "$1" ]]; then
echo "Usage: ./build-docker.sh def_file_name version_number"
@@ -11,18 +11,18 @@ if [[ -z "$2" ]]; then
fi
echo "Starting build..."
cp $1 ./prosody.deb
docker build -t prosody/prosody:$2 .
cp "$1" ./prosody.deb
docker build -t prosody/prosody:"$2" .
for i in "${@:3}"; do
echo "Also building tag $i"
docker build -t prosody/prosody:$i .
docker build -t prosody/prosody:"$i" .
done
docker push prosody/prosody
echo "Cleaning up..."
docker rmi prosody/prosody:$2
docker rmi prosody/prosody:"$2"
for i in "${@:3}"; do
echo "Also cleaning tag $i"
docker rmi prosody/prosody:$i
docker rmi prosody/prosody:"$i"
done
rm ./prosody.deb