Help us understand the problem. What is going on with this article?

CircleCI 2.1 の job をローカルの CLI で実行する

CircleCI の CLI はまだ 2.1 に対応していないようで、実行しようとするとエラーが発生する(Ver0.1.5725+b0a23c0)。

$ circleci local execute
Error: 
You attempted to run a local build with version '2.1' of configuration.
Local builds do not support that version at this time.
You can use 'circleci config process' to pre-process your config into a version that local builds can run (see 'circleci help config process' for more information)

回避策として

  • circleci config process コマンドで config.yml を CircleCI 2.1 形式から 2.0 形式に変換
    • このコマンドは config.yml をバリデーションしつつ同時に executorsorbs などを展開して出力してくれる
  • 変換後のファイルを使って job を実行

すればよい。

$ circleci config process .circleci/config.yml > process.yml
$ circleci local execute -c process.yml

ref: CircleCI のローカル CLI の使用 - CircleCI

Why not register and get more from Qiita?
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away
Comments
Sign up for free and join this conversation.
If you already have a Qiita account
Why do not you register as a user and use Qiita more conveniently?
You need to log in to use this function. Qiita can be used more conveniently after logging in.
You seem to be reading articles frequently this month. Qiita can be used more conveniently after logging in.
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away