Updated: 03 September 2023

Publish an App to CF

Every app to be published requires a manifest.yml file that defines some specifications for the app. An example of this can be seen below:

1
declared-services:
2
service-name:
3
label: Service Name
4
plan: free
5
applications:
6
name: unique-name-for-application
7
path: .
8
memory: 500M
9
instances: 1
10
services:
11
- Service Name
12
env:
13
NODE_ENV: dev

Setting Up Credentials

We make use of the .env to store the relevant API Keys for the services that out application will be using

Pushing an app to the cloud

The bx CLI is used to publish an app to the IBM cloud.

  1. Configure our api endpoint bx api https://api.eu-gb.bluemix.net (or another endpoint if you’re using a different server location, obviously)
  2. Next you log in with bx-login, however if you have a federated login then you need to make use of bx login -sso
  3. bx target cf will enable us to select the space and organization that we want to publish to
  4. Then we can push our app with bx app push which will upload our package, create a container and then deploy the container