0

I have installed the apic editor in Windows 10. I often get a 'Building v5 Gateway' error pop-up, when starting the the local server on the Assemble tab. The message says: "Error: It appears that Docker for Windows has not been installed..."

That's true - I'm not using it and don't want to use it! I did find a suggested fix (which I can't find now), which said: "set NO_PROXY=127.0.0.1".

This has appeared to work sometimes, but now it doesn't. It has worked when I set that variable in one command and followed it by 'apic edit'. I have since realised that you can chain 'set' cmds using && before 'apic edit'. I hoped that chaining NO_PROXY and 'apic'edit' would do the trick... but it didn't.

What kind of works, is to issue 'apic start' in a separate window. I end up with a running 'node.exe' window, and a failed 'Node.js' window... because it can't find an 'env.yaml' file (I've tracked down that this is because I started it outside the Designer). Which means I can test the api call.

I expect to be helping a customer to get started with APIC and this behaviour is not going to impress them. How can I get 'normal' service to be resumed?

Regards, John

2 Answers 2

1

Try to install docker for windows. Here is the link : Install Docker and restart your computer.

1
  • Hi @Atom. Thanks for suggestion. But, I don't want to use Docker. Neither, I assume will my customer. This has worked before without Docker. So, there must be a solution. I have an Ubuntu VM with apic installed that I got from an IBM workshop in 2016 - that never has this problem. My aim is to understand how to get apic editor working in Windows. John Mar 27, 2018 at 14:28
1

Solution

  1. Make sure any gateway instances are stopped

    apic stop
    
  2. Start the API Designer

    apic edit
    
  3. Within the API Designer, select your API and go to Assemble

  4. Make sure the policy palette panel in the left isn't collapsed. If it is, click the right arrow button (navigate icon)

  5. At the top of the policy palette panel, click the filter policies button (filter list icon)

  6. Make sure you select Micro Gateway policies

  7. Click save (save icon)

  8. Now click the play button (play icon) in the lower left to start the micro gateway

Alternatively, edit the Swagger yaml file for the API and make sure the micro gateway is configured:

x-ibm-configuration:
  gateway: micro-gateway

Note that if you've added any DataPower Gateway policies to your API, they will be disabled when running the micro gateway.

Details

API Connect requires a gateway to work. There are two different gateways:

  • The micro gateway, which is open-source but is much more limited. When running this in conjunction with the API Designer, the micro gateway will run as a Node.js app directly on your local machine.
  • The DataPower Gateway, which is a commercial product but can be used for free for development purposes. When running this with the API Designer, it will run as a container in Docker based on this image.

What kind of works, is to issue 'apic start' in a separate window.

By running apic start, you've manually started the micro gateway:

$ apic start
Service apic-gw started on port 4001.
$ apic services
Service apic-gw running on port 4001.
$ ps -eo command | grep gateway
/home/user/.nvm/versions/node/v6.14.4/bin/node /home/user/.nvm/versions/node/v6.14.4/lib/node_modules/apiconnect/node_modules/microgateway/datastore/server/server.js

The better way to start the gateway is from within the API Desginer by clicking the start button in the lower left. This will start the appropriate gateway for your API. If you see the "Building v5 Gateway" message, you've started the DataPower Gateway.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.