Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Foreman is not recomended to be installed via Gemfile #675

Closed
x2es opened this issue Jan 8, 2017 · 9 comments
Closed

Foreman is not recomended to be installed via Gemfile #675

x2es opened this issue Jan 8, 2017 · 9 comments

Comments

@x2es
Copy link
Contributor

x2es commented Jan 8, 2017

Hello,

Foreman is not recomended to be installed via Gemfile

https://github.com/ddollar/foreman

Ruby users should take care not to install foreman in their project's Gemfile.

We are using foreman in production deployment and experienced problems with different versions of foreman. We manage foreman by provisioning code and fix exact version.

foreman dependency here adds problems with integration for production in our case.

I think foreman may be included as development_dependency, since it is officially not recommended to include foreman into Gemfile. Nevertheless it affects development environment which acts as production like Docker/Vagrant VMs.

@x2es
Copy link
Contributor Author

x2es commented Jan 8, 2017

What we experienced with foreman:

  • different ps output for different versions of foreman - it breaks some maintenance bash tools;
  • npm react-s3-uploader was failing to finish upload file to S3 when server was started by foreman -f Procfile.dev, at the same time the same code works fine when server started by bundle exec rails s

So I treat foreman as source of unpredictable bugs and prefer to fix it version.

@justin808
Copy link
Member

@x2es Is there any recommended action to take here? Maybe you want to create a PR for a doc not in the /docs/additional-reading section?

@x2es
Copy link
Contributor Author

x2es commented Jan 9, 2017

^ I see solution like this PR #678

@justin808
Copy link
Member

@dylangrafmyre Would you agree with this?

@dylangrafmyre
Copy link
Contributor

dylangrafmyre commented Jan 10, 2017

@justin808 I agree that foreman should be removed from the Gemfile.

@x2es x2es closed this as completed Jan 11, 2017
@puneet-sutar
Copy link

@dylangrafmyre Will, it work if we add it to the Gemfile and with the require: false flag set?

@dylangrafmyre
Copy link
Contributor

@puneet-sutar Sorry I am not part of this project anymore. @justin808 should be able to assist you.

@x2es
Copy link
Contributor Author

x2es commented Mar 21, 2019

should to clarify about react-s3-uploader
The cause was in external env variable which was not accessible in context of foreman. So it was correct behaviour of foreman, and missed env in .env file

@puneet-sutar
It will work, just not recomended because it supposed to be installed globally, not per-project. foreman changing system-wide configuration, and if you will deploy multiple projects on the same server, it would be ambiguous what version of foreman is correct for server environment. Also version of foreman depends on version of server distro, so it is more devops dependency rather ruby project's.

And it should not be part of any gem dependency, because it will conflict in environments where foreman used globally as it supposed by authors.

@puneet-sutar
Copy link

@x2es Thanks for the information. Helps me better understand the use case.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants