IBM-Cloud / ibm-developer-extension-vscode

Extension for VS Code editor to enable IBM Cloud CLI capabilities from within the editing environment.
https://marketplace.visualstudio.com/items?itemName=IBM.ibm-developer
Apache License 2.0
13 stars 10 forks source link

feat: Added acct, region, api, resource commands and improved ux for deploy #42

Closed Aerex closed 2 years ago

Aerex commented 2 years ago

Context

This PR will add a few new VSCode commands as well as improve on UX for deploy. The following commands will be added:

In addition, the README has been updated to removed the old YouTube links and clarified some of the dev flow instructions.

Breaking Change

Steps To Test

Setup

  1. Install vsce npm package if not already: npm install -g vsce
  2. Checkout PR branch
  3. Run the command vsce package
  4. Verify vsix package is built successfully
  5. Open a starterkit project in VSCode
  6. Open the .ibm-project file and remove the values for the image-deploy-target and cluster-name if values exist
    • The dev deploy command will use the values in these properties to determine what cluster and image target to deploy. If they are not valid the deployment will fail
  7. Go to Extension -> Install From VSIX` and select vsix file created in step 4 2022-04-01_15-18
  8. Reload VSCode when requested

Test new commands

Note:

  1. Make sure to follow the steps in the Setup section
  2. Open the command palette
    • To enter Command Palette press Ctrl+Shift+P or F1 or navigate to View-> Command Palette
  3. Enter ibmcloud login --sso
  4. Follow the instructions to login into IBM Cloud
  5. Repeat step 2 (command palette)
  6. Enter the command ibmcloud account list
  7. Verify that step 6 runs successfully
  8. Repeat steps 5-7 except use the following commands:
    • ibmcloud account show
    • ibmcloud account users
    • ibmcloud api
    • ibmcloud regions
    • ibmcloud target
    • ibmcloud resource service-instances

Test new UX for dev deploy

Note: Before proceeding make sure that you have a working IBM Kubernetes Service (IKS) cluster and an image namespace in IBM Container Registry (CR)

  1. Make sure to follow the steps in the Setup section
  2. Login into to IBM Cloud by entering the command ibmcloud login --sso in the Command Palette
  3. Verify login is successful
  4. Build the project by entering the command ibmcloud dev build (release) in the Command Palette
  5. Verify build is successful
  6. Start deployment by entering the command ibmcloud dev deploy in the Command Palette
  7. Verify that terminal window is opened with the ibmcloud dev deploy executed
  8. Follow the prompts provided and verify that app is deployed successfully.
  9. Click on the link at the bottom of the terminal output and verify that app can be viewed in the browser

Videos

new_dev_deploy_iks

Aerex commented 2 years ago

@steveclay @schmidtp0740 Updated dev deploy command to utilize terminal to handle deployment.

steveclay commented 2 years ago

Probably should indicate in the README what the breaking change was --just one short line, not very verbose. I don't think I saw that there.

Aerex commented 2 years ago

@steveclay Added tidbit on breaking change in README