{"id":21019064,"url":"https://github.com/paalamugan/deploy-heroku-container-setup","last_synced_at":"2026-04-09T09:59:44.849Z","repository":{"id":114372980,"uuid":"431549460","full_name":"paalamugan/deploy-heroku-container-setup","owner":"paalamugan","description":"Instructions of how to setup react application using heroku container and docker cli. ","archived":false,"fork":false,"pushed_at":"2022-10-10T16:25:08.000Z","size":224,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-05-15T23:44:49.658Z","etag":null,"topics":["docker","docker-compose","heroku","nginx"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/paalamugan.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-11-24T16:09:37.000Z","updated_at":"2022-11-10T11:03:05.000Z","dependencies_parsed_at":null,"dependency_job_id":"96ac3fb6-e5b1-4257-b8ec-1a6bc73faf2e","html_url":"https://github.com/paalamugan/deploy-heroku-container-setup","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/paalamugan/deploy-heroku-container-setup","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paalamugan%2Fdeploy-heroku-container-setup","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paalamugan%2Fdeploy-heroku-container-setup/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paalamugan%2Fdeploy-heroku-container-setup/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paalamugan%2Fdeploy-heroku-container-setup/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/paalamugan","download_url":"https://codeload.github.com/paalamugan/deploy-heroku-container-setup/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paalamugan%2Fdeploy-heroku-container-setup/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28078439,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-12-27T02:00:05.897Z","response_time":58,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["docker","docker-compose","heroku","nginx"],"created_at":"2024-11-19T10:28:52.525Z","updated_at":"2025-12-27T12:04:18.989Z","avatar_url":"https://github.com/paalamugan.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Setup Instructions For Deploy Application In Heroku Container\n\n- How to setup react application using heroku container via docker cli.\n\n## Get Started\n\n- Install dependencies\n```\nyarn install\n```\n\n- For development,\n```\nyarn run start\n```\n\n- For production build,\n```\nyarn run build\n```\n\n## Deploy react application using heroku container cli\n\n- [Installation heroku instructions](https://devcenter.heroku.com/articles/heroku-cli)\n\n- Go to your root of the project folder and use below commands,\n    ```sh\n    heroku login\n    heroku plugins:install heroku-container-registry\n    heroku create ${YOUR_APP_NAME}\n    heroku container:login\n    heroku container:push web --app ${YOUR_APP_NAME}\n    heroku container:release web --app ${YOUR_APP_NAME}\n    heroku open --app ${YOUR_APP_NAME}\n    ```\n\n- Automatically deploy new changes to heroku after pushing to main branch, for example\n\n```sh\ngit add heroku.yml\ngit commit -m \"Add heroku.yml\"\n```\n\n- Set the stack of your app to container: (Only once)\n```sh\nheroku stack:set container\n```\n\n- Push your app to Heroku:\n```sh\ngit push heroku \u003cbranch_name\u003e\n```\n\n- After pushing to heroku, it will use the run command provided in `heroku.yml` instead of your `Procfile`.\n\n## Push Updated code to heroku using docker cli\n\n- Initial setup (Only once).\n```sh\ndocker login --username=_ --password=$(heroku auth:token) registry.heroku.com\n```\n\n- Create a tag `registry.heroku.com/${YOUR_APP_NAME}/web` that refers to `${EXISTING_IMAGE_NAME}` \n\n```sh\ndocker tag ${EXISTING_IMAGE_NAME} registry.heroku.com/${YOUR_APP_NAME}/web\n```\n\n- Build docker image again with new changes. \n```sh\ndocker build -t registry.heroku.com/${YOUR_APP_NAME}/web .\n```\n\n- Push the new local changes to production\n```sh\ndocker push registry.heroku.com/${YOUR_APP_NAME}/web\n```\n\n- When running a Docker container locally, you can set an environment variable using the -e flag:\n\n```sh\ndocker run -p 8080:80 -e PORT=80 ${IMAGE_NAME}\n```\n\n - Mutiple environment setup\n ```sh\n docker run -p 8080:80 --env-file .env ${IMAGE_NAME}\n ```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpaalamugan%2Fdeploy-heroku-container-setup","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpaalamugan%2Fdeploy-heroku-container-setup","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpaalamugan%2Fdeploy-heroku-container-setup/lists"}