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

Relocated the scope for common docker settings #392

Merged
merged 1 commit into from
Oct 27, 2014
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,8 @@ object DockerPlugin extends AutoPlugin {

override lazy val projectSettings = Seq(
dockerBaseImage := "dockerfile/java:latest",
dockerExposedPorts := Seq(),
dockerExposedVolumes := Seq(),
name in Docker <<= name,
packageName in Docker <<= packageName,
executableScriptName in Docker <<= executableScriptName,
Expand All @@ -74,8 +76,6 @@ object DockerPlugin extends AutoPlugin {
) ++ mapGenericFilesToDocker ++ inConfig(Docker)(Seq(
daemonUser := "daemon",
defaultLinuxInstallLocation := "/opt/docker",
dockerExposedPorts := Seq(),
dockerExposedVolumes := Seq(),
dockerPackageMappings <<= (sourceDirectory) map { dir =>
MappingsHelper contentOf dir
},
Expand Down
7 changes: 7 additions & 0 deletions src/sbt-test/docker/ports/build.sbt
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
enablePlugins(SbtNativePackager)

name := "simple-test"

version := "0.1.0"

dockerExposedPorts := Seq(9000)
1 change: 1 addition & 0 deletions src/sbt-test/docker/ports/project/plugins.sbt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
addSbtPlugin("com.typesafe.sbt" % "sbt-native-packager" % sys.props("project.version"))
3 changes: 3 additions & 0 deletions src/sbt-test/docker/ports/test
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Stage the distribution and ensure files show up.
> docker:stage
$ exec grep -q -F 'EXPOSE 9000' target/docker/Dockerfile