0

GitLab と統合された GitLab CI と、ランナーに推奨されるセカンダリ サーバーを使用しています。すべてが正しく構成されているようです。コミットを検出してビルド ステップを実行し、出力を確認できます。

少なくとも、次のデフォルト ジョブの場合:

git submodule update --init
ls -la

2 つのステップだけで 2 つ目のジョブを追加してみました。

npm install
gulp ci

を使ってgit cloneいるので、毎回インストールを実行したいです。

ビルドを実行しましたが、最初のジョブが繰り返されただけです。次に、2 番目のジョブを削除し、すべての手順をまとめました。

npm install
gulp ci
git submodule update --init
ls -la

ただし、ビルドからの出力は、デフォルト ジョブの場合とまったく同じです。このようなもの:

cd /home/gitlab_ci_runner/gitlab-ci-runner/tmp/builds && git clone https://gitlab-ci-token:<my-git-project-in-gitlab> project-3 && cd project-3 && git checkout aded9a5a66d754ef41504669e09fbd7393490a24
Cloning into 'project-3'...
Note: checking out 'aded9a5a66d754ef41504669e09fbd7393490a24'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -b with the checkout command again. Example:

  git checkout -b new_branch_name

HEAD is now at aded9a5... Merge branch 'master' of <my-repo>
cd /home/gitlab_ci_runner/gitlab-ci-runner/tmp/builds/project-3 && git reset --hard && git checkout aded9a5a66d754ef41504669e09fbd7393490a24
HEAD is now at aded9a5 Merge branch 'master' of <my-repo>
HEAD is now at aded9a5... Merge branch 'master' of <my-repo>
git submodule update --init
ls -la
<ls file list>

何か案は?ビルド スクリプトを変更して有効にするときに、クリアする必要があるキャッシュやボタンを押す必要があるものはありますか (設定の [変更を保存] を除いて)。

ありがとう。

4

2 に答える 2