Pages

Use PSM to push your application to ACCS

To push an application on the Application Container Cloud Service (ACCS) from the terminal, you can use the Oracle product 'PaaS Service Manager Command Line Interface' (PSM CLI). PSM CLI is a tool to help you with scripting tasks you want to do against several Oracle Clouds. The steps to push your application to the Oracle Cloud are not that complex, in short:

  1. We create a container in Storage Cloud for our application.
  2. We put the application archive in the Storage Container.
  3. We install the PSM CLI tool and connect it to our Cloud Identity.
  4. We setup the PSM tool with our username/password/etc. 
  5. We create an application container in ACCS using PSM using the archive from the Storage Cloud.
  6. We monitor the job progress using PSM. 

1. Create a container in Storage Cloud for our application.
curl -i -X PUT -u <username>:<password> \
 https://<identitydomain>.storage.oraclecloud.com/v1/Storage-<identitydomain>/<StorageContainer>


2. Put the application archive in the Storage Container.
curl -i -X PUT -u <username>:<password> \
 https://<identitydomain>.storage.oraclecloud.com/v1/Storage-<identitydomain>/<StorageContainer>/<zipname>.zip -T ./dist/<zipname>.zip



3. Install the PSM CLI tool and connect it to our Cloud Identity.
curl -X GET -u <username>:<password> -H X-ID-TENANT-NAME:<identitydomain> https://psm.us.oraclecloud.com/paas/core/api/v1.1/cli/<identitydomain>/client -o psmcli.zip


4. You have to run the command 'psm setup' to set up the connection to your cloud identity, provide username, password and the identity domain.


5. Create an application in ACCS using PSM using the archive from the Storage Cloud, you have to supply the manifest & depoyment description as well as the application name.
psm accs push -n <ApplicationName> -r node -s hourly -m ./manifest.json -d ./deployment.json -u <StorageContainer>/<zipname>.zip



6. Monitor the job progress.
Use the jobid you got back from the previous task to monitor the job progress, it might takes some time before the creation of the application is complete.
psm accs operation-status -j <jobId>




Once the job progress is completed, you should be able to access your application on Application Container Cloud.


Resources: