Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorEvan Read <eread@gitlab.com>2018-12-04 02:44:41 +0300
committerEvan Read <eread@gitlab.com>2018-12-04 02:44:41 +0300
commit3b44b2f3124b9bca943007e11939dfa7c49ea5cf (patch)
tree75b32ba110ed7dbc1952d3565e67a585e8e83c89 /doc
parente0143e60c703d6c042479db4039c3f7ec440a383 (diff)
parent34fbc8ea4dde147505e8d18d2199b58fe63b710e (diff)
Merge branch 'patch-28' into 'master'
Rollback will not work because Envoy will still fetch latest commit from theā€¦ See merge request gitlab-org/gitlab-ce!23493
Diffstat (limited to 'doc')
-rw-r--r--doc/ci/examples/laravel_with_gitlab_and_envoy/index.md6
1 files changed, 5 insertions, 1 deletions
diff --git a/doc/ci/examples/laravel_with_gitlab_and_envoy/index.md b/doc/ci/examples/laravel_with_gitlab_and_envoy/index.md
index b090ea014dc..b1ccce744d8 100644
--- a/doc/ci/examples/laravel_with_gitlab_and_envoy/index.md
+++ b/doc/ci/examples/laravel_with_gitlab_and_envoy/index.md
@@ -273,6 +273,8 @@ The `releases` directory will hold all our deployments:
echo 'Cloning repository'
[ -d {{ $releases_dir }} ] || mkdir {{ $releases_dir }}
git clone --depth 1 {{ $repository }} {{ $new_release_dir }}
+ cd {{ $releases_dir }}
+ git reset --hard {{ $commit }}
@endtask
...
@@ -349,6 +351,8 @@ At the end, our `Envoy.blade.php` file will look like this:
echo 'Cloning repository'
[ -d {{ $releases_dir }} ] || mkdir {{ $releases_dir }}
git clone --depth 1 {{ $repository }} {{ $new_release_dir }}
+ cd {{ $releases_dir }}
+ git reset --hard {{ $commit }}
@endtask
@task('run_composer')
@@ -519,7 +523,7 @@ deploy_production:
- mkdir -p ~/.ssh
- '[[ -f /.dockerenv ]] && echo -e "Host *\n\tStrictHostKeyChecking no\n\n" > ~/.ssh/config'
- - ~/.composer/vendor/bin/envoy run deploy
+ - ~/.composer/vendor/bin/envoy run deploy --commit="$CI_COMMIT_SHA"
environment:
name: production
url: http://192.168.1.1