How to Gitlab サーバのアップグレードによるGitlab-runnerが変な動きと容量不足の話…

先日、How to Gitlab バージョンを上げる話(2021/10/08)にてGitlabのバージョンを上げてからパイプラインが落ちます…具体的には、npacking gitlab-ee (14.3.2-ee.0) over (14.2.4-ee.0) …です。

そのメモを残しておきます

エラーーっぽい部分

$ composer install
Installing dependencies from lock file (including require-dev)
Verifying lock file contents can be installed on current platform.
Package operations: 111 installs, 0 updates, 0 removals
    Failed to download doctrine/inflector from dist: The zip extension and unzip/7z commands are both missing, skipping.
The php.ini used by your command-line PHP is: /usr/local/etc/php/conf.d/docker-php-ext-sodium.ini
    Now trying to download from source
  - Syncing doctrine/inflector (2.0.3) into cache
    Failed to download doctrine/lexer from dist: The zip extension and unzip/7z commands are both missing, skipping.
The php.ini used by your command-line PHP is: /usr/local/etc/php/conf.d/docker-php-ext-sodium.ini
    Now trying to download from source
  - Syncing doctrine/lexer (1.2.1) into cache
    Failed to download symfony/polyfill-ctype from dist: The zip extension and unzip/7z commands are both missing, skipping.

エラーメッセージ

  [RuntimeException]                                                                                                 
  Failed to clone https://github.com/sebastianbergmann/comparator.git via https, ssh protocols, aborting.            
                                                                                                                     
  - https://github.com/sebastianbergmann/comparator.git                                                              
    Cloning into bare repository '/root/.composer/cache/vcs/https---github.com-sebastianbergmann-comparator.git'...  
    fatal: write error: No space left on device                                                                      
    fatal: index-pack failed                                                                                         
                                                                                                                     
  - git@github.com:sebastianbergmann/comparator.git                                                                  
    Cloning into bare repository '/root/.composer/cache/vcs/https---github.com-sebastianbergmann-comparator.git'...  
    Host key verification failed.                                                                                    
    fatal: Could not read from remote repository.                                                                    
                                                                                                                     
    Please make sure you have the correct access rights                                                              
    and the repository exists.                                                                                       
                                                                                                                     
install [--prefer-source] [--prefer-dist] [--prefer-install PREFER-INSTALL] [--dry-run] [--dev] [--no-suggest] [--no-dev] [--no-autoloader] [--no-scripts] [--no-progress] [--no-install] [-v|vv|vvv|--verbose] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--apcu-autoloader] [--apcu-autoloader-prefix APCU-AUTOLOADER-PREFIX] [--ignore-platform-req IGNORE-PLATFORM-REQ] [--ignore-platform-reqs] [--] [<packages>]...

日本語訳すると… よくわからん!つまりは… 「No space left on device」だよねぇ〜wデジャヴュ

How to Gitlab バージョンを上げる話(2021/10/08)を参考にgitlab-runnerの容量アップ(デフォルトが10GB程度なのが悪い)

早速… とおもったら、

なんだか起こっていらっしゃいます… 「利用不能?」

忘れていましたが、「14.2.0」の部分をとりあえず解消する

Gitlab-runnerのアップグレード方法

公式にある通りにすればOKです

sudo gitlab-runner stop

sudo curl -L --output /usr/local/bin/gitlab-runner "https://gitlab-runner-downloads.s3.amazonaws.com/latest/binaries/gitlab-runner-linux-amd64"

sudo chmod +x /usr/local/bin/gitlab-runner

sudo gitlab-runner start

これで無事に上がります

wataru@gitlab-runner:~$ sudo gitlab-runner -version
Version:      14.3.2
Git revision: e0218c92
Git branch:   14-3-stable
GO version:   go1.13.8
Built:        2021-09-30T16:10:52+0000
OS/Arch:      linux/amd64

お嬢様は、相変わらずご機嫌斜めですが、使えるからいっかなw

今後の課題とか

気になったポイントは、composer installで

The php.ini used by your command-line PHP is: /usr/local/etc/php/conf.d/docker-php-ext-sodium.ini
    Now trying to download from source
  - Syncing nunomaduro/collision (v5.10.0) into cache
    Failed to download phpdocumentor/reflection-common from dist: The zip extension and unzip/7z commands are both missing, skipping.

この部分がすぱぱぱぱーっと通ると早い気がするんだよなぁ〜

Failed to download… って