-
Notifications
You must be signed in to change notification settings - Fork 521
CLOUDP-83092: Add context images for agents. #435
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
Merged
Merged
Changes from all commits
Commits
Show all changes
20 commits
Select commit
Hold shift + click to select a range
f03b298
CLOUDP-83092: Add init container images to inventory file
chatton 5373ffa
updated evergreen.yml
chatton 363e140
fixed .evergreen.yml
chatton 92fd0d8
add release tasks for hooks
chatton b9cfe85
release to correct registry
chatton a6b9103
add release tasks for probes
chatton 8fa828d
Merge branch 'master' into CLOUDP-83092_add_release_task_for_init_con…
chatton 8ebb780
added agent context images
chatton b642729
corrected skiptags
chatton 1cafc42
Merge branch 'CLOUDP-83092_add_release_task_for_init_containers' of g…
chatton 4c40f97
added ensure_tag function
chatton 5f3a84d
added type hinting for list
chatton 5e9413e
added tags
chatton cfa0c43
added ubuntu and ubi tags
chatton a7bed44
merge master
chatton 151c70d
add release tasks for init container
chatton a382dae
merged branch
chatton 69ee54d
merged master
chatton b435456
addressed PR feedback
chatton fc01018
Merge branch 'master' into CLOUDP-83092_add_context_image_for_agents
chatton File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,6 +1,5 @@ | ||
| .github | ||
| .idea | ||
| agent | ||
| zz_* | ||
| vendor/ | ||
| scripts/ | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,11 @@ | ||
| FROM scratch | ||
|
|
||
| ARG agent_version | ||
| ARG agent_distro | ||
| ARG tools_distro | ||
| ARG tools_version | ||
|
|
||
| ADD https://mciuploads.s3.amazonaws.com/mms-automation/mongodb-mms-build-agent/builds/automation-agent/prod/mongodb-mms-automation-agent-${agent_version}.${agent_distro}.tar.gz /data/mongodb-agent.tar.gz | ||
| ADD https://downloads.mongodb.org/tools/db/mongodb-database-tools-${tools_distro}-${tools_version}.tgz /data/mongodb-tools.tgz | ||
|
|
||
| ADD agent/LICENSE /data/licenses |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,29 +1,32 @@ | ||
| ARG imagebase | ||
| FROM ${imagebase} as base | ||
|
|
||
| FROM {{base_image}} | ||
|
|
||
| {% block packages -%} | ||
| {% endblock -%} | ||
|
|
||
| RUN mkdir -p agent \ | ||
| && curl --fail --retry 3 --silent https://mciuploads.s3.amazonaws.com/mms-automation/mongodb-mms-build-agent/builds/automation-agent/prod/mongodb-mms-automation-agent-{{agent_version}}.{{agent_distro}}.tar.gz -o agent/mongodb-agent.tar.gz \ | ||
| && tar xfz agent/mongodb-agent.tar.gz \ | ||
| && mv mongodb-mms-automation-agent-*/mongodb-mms-automation-agent agent/mongodb-agent \ | ||
| && chmod +x agent/mongodb-agent \ | ||
| RUN mkdir -p /agent \ | ||
| && mkdir -p /var/lib/mongodb-mms-automation \ | ||
| && mkdir -p /var/log/mongodb-mms-automation/ \ | ||
| && chmod -R +wr /var/log/mongodb-mms-automation/ \ | ||
| # ensure that the agent user can write the logs in OpenShift | ||
| && touch /var/log/mongodb-mms-automation/readiness.log \ | ||
| && chmod ugo+rw /var/log/mongodb-mms-automation/readiness.log | ||
|
|
||
|
|
||
| COPY --from=base /data/mongodb-agent.tar.gz /agent | ||
| COPY --from=base /data/mongodb-tools.tgz /agent | ||
|
|
||
| RUN tar xfz /agent/mongodb-agent.tar.gz \ | ||
| && mv mongodb-mms-automation-agent-*/mongodb-mms-automation-agent /agent/mongodb-agent \ | ||
| && chmod +x /agent/mongodb-agent \ | ||
| && mkdir -p /var/lib/automation/config \ | ||
| && chmod -R +r /var/lib/automation/config \ | ||
| && rm agent/mongodb-agent.tar.gz \ | ||
| && rm /agent/mongodb-agent.tar.gz \ | ||
| && rm -r mongodb-mms-automation-agent-* | ||
|
|
||
| RUN mkdir -p /var/lib/mongodb-mms-automation \ | ||
| && mkdir -p /var/log/mongodb-mms-automation/ \ | ||
| && chmod -R +wr /var/log/mongodb-mms-automation/ \ | ||
| # ensure that the agent user can write the logs in OpenShift | ||
| && touch /var/log/mongodb-mms-automation/readiness.log \ | ||
| && chmod ugo+rw /var/log/mongodb-mms-automation/readiness.log | ||
|
|
||
| # Install MongoDB tools. The agent will automatically search the folder and find the binaries. | ||
| RUN curl --fail --retry 3 --silent https://downloads.mongodb.org/tools/db/mongodb-database-tools-{{tools_distro}}-{{tools_version}}.tgz -o mongodb-tools.tgz \ | ||
| && tar xfz mongodb-tools.tgz --directory /var/lib/mongodb-mms-automation/ \ | ||
| && rm mongodb-tools.tgz | ||
| RUN tar xfz /agent/mongodb-tools.tgz --directory /var/lib/mongodb-mms-automation/ && rm /agent/mongodb-tools.tgz | ||
|
|
||
| USER 2000 | ||
| CMD ["agent/mongodb-agent", "-cluster=/var/lib/automation/config/automation-config.json"] | ||
| CMD ["/agent/mongodb-agent", "-cluster=/var/lib/automation/config/automation-config.json"] |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you fixed this already :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we haven't yet released 0.10.0, but let's do that now, no harm!