Skip to content

Scripts to build, deploy and run an Adobe I/O cloud native app

License

Notifications You must be signed in to change notification settings

ahmed-musallam/aio-app-scripts

 
 

Repository files navigation

Version Downloads/week Build Status License Greenkeeper badge Codecov Coverage

AIO App Scripts

Utility tooling scripts to build, deploy and run Adobe I/O Apps

Include as a library in your nodejs project

npm i --save @adobe/aio-app-scripts
const appScripts = require('@adobe/aio-app-scripts')({
  listeners: {
    onStart: taskName => console.error(`${taskName} ...`),
    onEnd: (taskName, res) => { console.error(`${taskName} done!`); if (res) console.log(res) },
    onWarning: warning => console.error(warning),
    onProgress: item => console.error(`  > ${item}`)
  }
})

appScripts.buildUI()
  .then(appScripts.buildActions)
  .then(appScripts.deployActions)
  .then(appScripts.deployUI)
  .catch(e => { console.error(e); process.exit(1) })

Install globally to run directly

note this interface is experimental and may disappear in the future

npm i -g @adobe/aio-app-scripts

Commands:

aio-app-scripts build.actions
aio-app-scripts build.ui
aio-app-scripts deploy.actions
aio-app-scripts deploy.ui
aio-app-scripts undeploy.actions
aio-app-scripts undeploy.ui

Using aio-app-scripts for local dev

  • run dev server, this will spin up a local OpenWhisk stack and run a server for the frontend

Requires docker! Requires Java!

   aio-app-scripts dev
  • only run frontend server, the frontend will point to remotely deployed actions
   REMOTE_ACTIONS=true aio-app-scripts dev

Debugging with VS Code

Requires docker! Requires @adobe/wskdebug in application

  • Actions can be debugged in both with local dev and remote actions dev modes

  • Simply start the dev server aio-app-scripts dev, this will generate all needed vscode debug configurations

  • Then start the vs code debugger from the configuration you want, i.e. choose WebAndActions to debug all actions and UI simultaneously or choose separate debuggers.

  • When you stop the dev server all vs code configurations are cleaned up and restored.

Explore

Contributing

Contributions are welcomed! Read the Contributing Guide for more information.

Licensing

This project is licensed under the Apache V2 License. See LICENSE for more information.

About

Scripts to build, deploy and run an Adobe I/O cloud native app

Resources

License

Code of conduct

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 99.8%
  • HTML 0.2%