ember-cli-deploy-docker-hub
v0.0.2
Published
ember-cli-deploy plugin to build and upload docker images to Docker Hub.
Downloads
3
Maintainers
Readme
ember-cli-deploy-docker-hub
An ember-cli-deploy plugin to build a docker image and upload it to a repository (Docker hub)
What is an ember-cli-deploy plugin?
A plugin is an addon that can be executed as a part of the ember-cli-deploy pipeline. A plugin will implement one or more of the ember-cli-deploy's pipeline hooks. This plugin will be executed on the 'upload' hook.
This component is part of the rewrite of the frontend-app for my job at easyPEP/staffomatic.
- easyPEP (german name): homepage
- Staffomatic (english name): homepage
- easyPEP github
For more information on what plugins are and how they work, please refer to the Plugin Documentation.
Quick Start
To get up and running quickly, do the following:
- Ensure you are logged in with your docker cli: docs
- Ensure ember-cli-deploy-build is installed and configured.
- Ensure ember-cli-deploy-revision-data is installed and configured.
- Install this plugin
$ ember install ember-cli-deploy-docker-hub
- Place the following configuration into
config/deploy.js
ENV["docker-hub"] = {
repository: 'company/repository', // required
dockerFilePath: 'docker/Dockerfile' // default 'Dockerfile'
}
- Run the pipeline
$ ember deploy
Configuration Options
For detailed information on how configuration of plugins works, please refer to the Plugin Documentation.
repository
The name of your repository at Docker hub.
Default: undefined
dockerFilePath
The path to your Dockerfile relative to your project root.
Default: Dockerfile
What does the plugin do?
ember-cli-deploy-docker-hub builds your image once with the revisionKey
from ember-cli-deploy-revision-data
as a tag and once with the latest
tag.
Equivalent to:
$ docker build -f 'dockerFilePath' -t repository:123456 .;
$ docker build -f 'dockerFilePath' -t repository:latest .;
Then it simply pushes the images to docker hub.
$ docker push repository:123456;
$ docker push repository:latest;
When does the plugin execute?
Activation occurs during the upload
hook of the pipeline.
TODO
- I don't know how to test this yet. So yes, sadly there are no tests yet.
- Try this out with other repository hosters.
- Configure which deploy hook triggers the plugin