mirror of
https://github.com/shlinkio/shlink.git
synced 2025-03-14 04:00:57 +03:00
Merge pull request #686 from acelaya-forks/feature/reduce-docker-image
Feature/reduce docker image
This commit is contained in:
commit
f9318bb1b3
3 changed files with 8 additions and 5 deletions
|
@ -8,17 +8,18 @@ data/migrations_template.txt
|
|||
data/GeoLite2-City.*
|
||||
data/database.sqlite
|
||||
data/shlink-tests.db
|
||||
**/.gitignore
|
||||
CHANGELOG.md
|
||||
UPGRADE.md
|
||||
composer.lock
|
||||
vendor
|
||||
docs
|
||||
indocker
|
||||
docker-*
|
||||
php*
|
||||
.php*
|
||||
infection.json
|
||||
phpstan.neon
|
||||
**/test*
|
||||
build*
|
||||
.github
|
||||
hooks
|
||||
.git*
|
||||
.scrutinizer.yml
|
||||
.travis.yml
|
||||
|
|
|
@ -41,6 +41,8 @@ FROM base as builder
|
|||
COPY . .
|
||||
COPY --from=composer:1.10.1 /usr/bin/composer ./composer.phar
|
||||
RUN php composer.phar install --no-dev --optimize-autoloader --prefer-dist --no-progress --no-interaction && \
|
||||
php composer.phar clear-cache && \
|
||||
rm composer.* && \
|
||||
sed -i "s/%SHLINK_VERSION%/${SHLINK_VERSION}/g" config/autoload/app_options.global.php
|
||||
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@ echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin
|
|||
|
||||
# If there is a tag, regardless the branch, build that docker tag and also "stable"
|
||||
if [[ ! -z $TRAVIS_TAG ]]; then
|
||||
docker build --build-arg VERSION=${TRAVIS_TAG#?} -t shlinkio/shlink:${TRAVIS_TAG#?} -t shlinkio/shlink:stable .
|
||||
docker build --build-arg SHLINK_VERSION=${TRAVIS_TAG#?} -t shlinkio/shlink:${TRAVIS_TAG#?} -t shlinkio/shlink:stable .
|
||||
docker push shlinkio/shlink:${TRAVIS_TAG#?}
|
||||
docker push shlinkio/shlink:stable
|
||||
# If build branch is develop, build latest (on master, when there's no tag, do not build anything)
|
||||
|
|
Loading…
Add table
Reference in a new issue