github.com/tototoman/operator-sdk@v0.8.2/doc/user/install-operator-sdk.md (about)

     1  # Install the Operator SDK CLI
     2  
     3  ## Install from GitHub release
     4  
     5  ### Download the release binary
     6  
     7  ```sh
     8  # Set the release version variable
     9  RELEASE_VERSION=v0.8.2
    10  # Linux
    11  $ curl -OJL https://github.com/operator-framework/operator-sdk/releases/download/${RELEASE_VERSION}/operator-sdk-${RELEASE_VERSION}-x86_64-linux-gnu
    12  # macOS
    13  $ curl -OJL https://github.com/operator-framework/operator-sdk/releases/download/${RELEASE_VERSION}/operator-sdk-${RELEASE_VERSION}-x86_64-apple-darwin
    14  ```
    15  
    16  #### Verify the downloaded release binary
    17  
    18  ```sh
    19  # Linux
    20  curl -OJL https://github.com/operator-framework/operator-sdk/releases/download/${RELEASE_VERSION}/operator-sdk-${RELEASE_VERSION}-x86_64-linux-gnu.asc
    21  # macOS
    22  curl -OJL https://github.com/operator-framework/operator-sdk/releases/download/${RELEASE_VERSION}/operator-sdk-${RELEASE_VERSION}-x86_64-apple-darwin.asc
    23  ```
    24  
    25  To verify a release binary using the provided asc files, place the binary and corresponding asc file into the same directory and use the corresponding command:
    26  
    27  ```sh
    28  # Linux
    29  $ gpg --verify operator-sdk-${RELEASE_VERSION}-x86_64-linux-gnu.asc
    30  # macOS
    31  $ gpg --verify operator-sdk-${RELEASE_VERSION}-x86_64-apple-darwin.asc
    32  ```
    33  
    34  If you do not have the maintainers public key on your machine, you will get an error message similar to this:
    35  
    36  ```sh
    37  $ gpg --verify operator-sdk-${RELEASE_VERSION}-x86_64-apple-darwin.asc
    38  $ gpg: assuming signed data in 'operator-sdk-${RELEASE_VERSION}-x86_64-apple-darwin'
    39  $ gpg: Signature made Fri Apr  5 20:03:22 2019 CEST
    40  $ gpg:                using RSA key <KEY_ID>
    41  $gpg: Can't check signature: No public key
    42  ```
    43  
    44  To download the key, use the following command, replacing `$KEY_ID` with the RSA key string provided in the output of the previous command:
    45  
    46  ```sh
    47  $ gpg --recv-key "$KEY_ID"
    48  ```
    49  
    50  Now you should be able to verify the binary.
    51  
    52  
    53  ### Install the release binary in your PATH
    54  
    55  ```
    56  # Linux
    57  $ chmod +x operator-sdk-${RELEASE_VERSION}-x86_64-linux-gnu && sudo cp operator-sdk-${RELEASE_VERSION}-x86_64-linux-gnu /usr/local/bin/operator-sdk && rm operator-sdk-${RELEASE_VERSION}-x86_64-linux-gnu
    58  # macOS
    59  $ chmod +x operator-sdk-${RELEASE_VERSION}-x86_64-apple-darwin && sudo cp operator-sdk-${RELEASE_VERSION}-x86_64-apple-darwin /usr/local/bin/operator-sdk && rm operator-sdk-${RELEASE_VERSION}-x86_64-apple-darwin
    60  ```
    61  
    62  ## Install from Homebrew
    63  
    64  Alternatively, if you are using [Homebrew][homebrew_tool], you can install the SDK CLI tool with the following command:
    65  
    66  ```sh
    67  $ brew install operator-sdk
    68  ```
    69  
    70  ## Compile and install from master
    71  
    72  ```sh
    73  $ mkdir -p $GOPATH/src/github.com/operator-framework
    74  $ cd $GOPATH/src/github.com/operator-framework
    75  $ git clone https://github.com/operator-framework/operator-sdk
    76  $ cd operator-sdk
    77  $ git checkout master
    78  $ make dep
    79  $ make install
    80  ```
    81  
    82  [homebrew_tool]:https://brew.sh/