Skip to content

Deployment on Heroku #2517

Closed
Closed
@splacentino

Description

@splacentino

Versions.

angular-cli: 1.0.0-beta.16
node: 6.6.0

Hi. I would like to deploy my angular2 app on a Heroku web dyno. What is the best way to do it using angular-cli.

At this time, I build the prod. version locally and push my dist/ folder on Git. Then I use http-server to serve the static files from dist/

    "start.prod": "http-server dist/",
    "build.prod": "ng build --prod",

Procfile

npm run start.prod

There would probably be a cleaner way to do it. I can't make CLI working on the Heroku dyno so I am not able to build the app on it.

Thanks in advance.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions