GitHub Actions give us a new way to deploy to Heroku, and to integrate Heroku with other parts of our development workflows. In a single GitHub Act...
For further actions, you may consider blocking this person and/or reporting abuse
Hi! thank you for the article!
We also push from GH Actions to Heroku, but we just use git push since it seems it's easier, what's the difference doing it this way or just pushing? Does the build takes less time or more? Thanks!
What we do is:
What do you recommend?
Thanks!
Hey Javier!
That’s awesome to hear. It’s not a straight pro/con toss-up, and which builds faster is going to depend on your stack, and that for the most part is also going to decide whether git or docker is better for you.
Docker is going to give you greater flexibility in what you run on Heroku, as you are providing the container. But git is going to be using the Heroku-curated environments that they do a lot of work to optimise around. There’s also, I believe, some features that are less supported for Docker, for example I believe Review Apps isn’t available if you go a certain route for docker deploys.
Hi! We're using docker, heroku.yml, and the container stack! But instead of pushing to the container registry we use git push to Heroku, I don't understand if there is any difference in doing it your way or the way we do since both are docker deploys.
Thank you for your answer!
Hi! great article, I was just curious about how the migration files would be executed. I tried this:
But I get "the input device is not a TTY".
And you can add an environment variable for all the steps added to your job, like this:
Hi, thanks for the article. I followed the same step to configure an heroku deployment but I get this error:
Run heroku container:push -a habu-server web
heroku container:push -a habu-server web
shell: /bin/bash -e {0}
env:
HEROKU_API_KEY: ***
› Warning: heroku update available from 7.47.3 to 7.47.4.
▸ No images to push
Error: Process completed with exit code 1.
Change
ubuntu-latest
toubuntu-20.04
.Add this source code before
Login to Heroku Container registry
Hey!!
I tried to add the code above, but I still have the same error
Is your Dockerfile in a subdirectory? If so, change the Dockerfile file name as "Dockerfile.web" and modify heroku push command as "heroku container:push -a $APP_NAME --context-path . --recursive"
In here recursive searches Dockerfiles in current and subdirectories, context-path is specifies build context which is root directory.
Thank you very much for the article ! I found it very helpful.
But as I'm not really an expert in Docker I was wondering how you can pass environement variables for the build of the container and for the execution ?
I don't know if what I say is really clear, let me know if it isn't 😅
Hi, thank you for the article :)
I wonder how it is possible to use Heroku CLI even there aren't any codes about Heroku installation.
Does ubuntu-latest install by default or about actions/checkouts?
Thank you!
ENDED UP WITH THIS ERROR
Run heroku container:push -a *** web
▸ Couldn't find that app.
[error]Process completed with exit code 1.
@manojap and @iamjithindas
Switch to a new source code:
I ended up with the same error. have you found what's the problem?
can you pass enviroment-vars to the container aswell? Say you have a connectionUrl in your secrets you want to pass :D
Yes you can! You just set them as inputs in the Action's metadata
Great article and everything was working perfectly till I added environmental variables in my project and now the build is failing. Could you elaborate a bit more on how to pass the environmental variables to the container? Thanks a lot!
Great article, man. Help me a lot. =)
Very helpful, thanks a lot!