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

Fixes Procfile extraction in Docker 1.12. #915

Merged
merged 2 commits into from
Jul 11, 2016
Merged

Fixes Procfile extraction in Docker 1.12. #915

merged 2 commits into from
Jul 11, 2016

Conversation

ejholmes
Copy link
Contributor

@ejholmes ejholmes commented Jul 2, 2016

Fixes #899.

This adds support for using the /containers/:id/archive endpoint when the Docker API version 1.24 or greater is used.

@mwildehahn
Copy link
Contributor

mwildehahn commented Jul 11, 2016

👍

@ejholmes ejholmes merged commit ea7a64f into master Jul 11, 2016
@ejholmes ejholmes deleted the docker-1.12 branch July 11, 2016 23:25
@gswallow
Copy link

gswallow commented Dec 23, 2016

Talked with mikeb today on Slack. This issue may still be lingering around. I had issues with 0.10.0 and 0.10.1 running alongside Docker 1.12.3.

Updated to Ubuntu 16.04 because we kept running into storage issues, and figured, why not? Let's update to Docker 1.12.3. All of our apps were being set up as "web" apps; not "worker" apps. After rebuilding an AMI with Docker 1.11.2, redeploying Empire AMIs with version 0.10.0, and finally dropping all of the tables (we had been running 0.10.1), I get the appropriate behavior:

emp env-load qa-env/environments/qa2/all.env -a archive-reporter
emp set -a archive-reporter DAEMON=reporter.rb
emp deploy -a archive-reporter indigobio/web-daemonizer:e5f20af
emp scale -a archive-reporter workerservice=1:1x

emp scale -l -a archive-reporter
workerservice=1:1X

Conversation earlier today:

gswallow [7:47 PM]
you guys around?

mikeb [7:48 PM]
I’m in and out - in Texas on vacation, but here right now if you have a quick question 🙂

gswallow [7:48 PM]
Been cussing at docker/empire/xenial all day so bear with me

[7:48]
I updated to 0.10.1

[7:48]
now it seems to be ignoring my procfiles

mikeb [7:48 PM]
Ignoring the CMD entry you mean as the default command?

[7:48]
oh, sorry, confused 🙂

[7:48]
ignoring your procfile completely?

gswallow [7:49 PM]
the Procfile labels a container as a workerservice

mikeb [7:49 PM]
What’s in the Procfile?

gswallow [7:49 PM]
but when I run emp scale -l -a it says web=1:1x

[7:49]
workerservice: ./empire.run

[7:50]
docker 1.12.3

mikeb [7:50 PM]
Ah, ok - does your Dockerfile have a CMD entry?

gswallow [7:50 PM]
saw bug #915

[7:50]
no

[7:50]
that’s it

[7:50]
oh the dockerfile

mikeb [7:50 PM]
the Dockerfile, not the Procfile 🙂

[7:50]
yeah

[7:50]
So, a few things about empire defaults.

[7:51]

  1. If there is a web process, empire automatically scales it to 1.

[7:51]
2. If there is no web process listed in the Procfile, it automatically uses the CMD in the Dockerfile as the web process.

[7:51]
So if you line up 1 & 2 just right, I could see it bringing up what it calls a “web” process.

gswallow [7:51 PM]
There is a CMD in one of the docker files (there are several dockerfiles)

mikeb [7:52 PM]
my guess is that we never really thought of that combination, so it could be seen as a bug, though it’s behaving as expected.

[7:52]
does it spin up a web process in the app that doesn’t have a CMD and doesn’t have a web defined in the Procfile?

gswallow [7:52 PM]
there’s a Dockerfile.ascent-web-base, which I think gets inherited by the web and workerservice “downstream” dockerfiles.

[7:53]
I don’t understand your question

mikeb [7:53 PM]
Do you have an app your deploying that has no web entry in it’s Procfile and has no CMD entry in it’s Dockerfile either?

gswallow [7:53 PM]
yes

[7:53]
or...

mikeb [7:53 PM]
and it spins up a web process still?

gswallow [7:53 PM]
Let me clarify

[7:53]
I spin up an app

[7:53]
its procfile says:

[7:54]
workerservice: ./empire.run

[7:54]
that’s it

mikeb [7:54 PM]
ok

gswallow [7:54 PM]
But the dockerfile inherits from another docker file

mikeb [7:54 PM]
do either of those docker files have a CMD entry?

gswallow [7:54 PM]
yes

[7:54]
the base does

mikeb [7:54 PM]
Ok, not sure how you are doing inheritance (ONBUILD?)

gswallow [7:54 PM]
FROM

mikeb [7:55 PM]
Ahh, ok, yeah - so it should inherit the CMD entry

gswallow [7:55 PM]
So that’s getting run as a web app?

mikeb [7:55 PM]
at least I’m pretty sure, it’s been a while since I’ve dug into that

[7:55]
yeah

gswallow [7:55 PM]
well, damn

[7:55]
I guess I downgrade.

mikeb [7:55 PM]
it did that before .10.1 though I’m pretty sure

[7:55]
That isn’t really new functionality

gswallow [7:55 PM]
we were on a specific git hash

mikeb [7:56 PM]
yeah, this functionality has been in here for a long time though

gswallow [7:56 PM]
pre 0.10.0

mikeb [7:56 PM]
maybe something change recently that enabled this particular change

gswallow [7:56 PM]
I just upgraded to 0.10.1 wondering if it was bug #915

[7:56]
let me try downgrading. Really, I’m having problems with lvm-thinpools. AUFS will cause us all sorts of headaches.

mikeb [7:57 PM]
ahhh, yeah, that’s possible - if you’re using a new docker, the yeah, it was broken

[7:57]
not sure how it acted though when it broke

gswallow [7:57 PM]
We updated from 1.11.x to 1.12.3 iirc

mikeb [7:57 PM]
gotcha

gswallow [7:57 PM]
If I search the packages and there is no 1.11.x for 16.04 I’m going to scream.

[7:58]
1.11.2. yay

mikeb [7:58 PM]
You can also scale down that process after it’s deployed 🙂 that said, I wouldn’t be against seeing a bug against this, so we can at least think if this is really the behavior we want

gswallow [7:58 PM]
I can copy/paste this convo if it helps. I still need to toy with versions

mikeb [7:59 PM]
Cool - yeah, dig into it, and if you can open a bug that’d be awesome 🙂

gswallow [7:59 PM]
thanks. enjoy the remainder of your vacation

new messages
mikeb [7:59 PM]
Thanks!

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

Successfully merging this pull request may close these issues.

None yet

3 participants