Skip to content

Commit

Permalink
feat: Package as a debian artifact
Browse files Browse the repository at this point in the history
Co-authored-by: Joe Griffiths <[email protected]>
  • Loading branch information
akash1810 and Joemgru committed Jan 30, 2025
1 parent 81e74b6 commit 1c8e5e3
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
14 changes: 8 additions & 6 deletions project/ProjectSettings.scala
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,13 @@ package com.gu

import com.gu.versioninfo.VersionInfo
import com.typesafe.sbt.packager.universal.UniversalPlugin
import sbt._
import sbt.Keys._
import com.gu.Dependencies._
import play.sbt.{PlayPekkoHttpServer, PlayNettyServer, PlayScala}
import sbt.*
import sbt.Keys.*
import com.gu.Dependencies.*
import play.sbt.{PlayNettyServer, PlayPekkoHttpServer, PlayScala}
import com.typesafe.sbt.SbtNativePackager.Universal
import com.typesafe.sbt.packager.Keys.packageName
import com.typesafe.sbt.packager.debian.JDebPackaging
import sbtbuildinfo.{BuildInfoKey, BuildInfoOption, BuildInfoPlugin}
import sbtbuildinfo.BuildInfoKeys.{buildInfoKeys, buildInfoOptions, buildInfoPackage}

Expand Down Expand Up @@ -60,7 +61,8 @@ object ProjectSettings {
}

val frontendTestSettings = Seq(
Test / testOptions += Tests.Argument(TestFrameworks.ScalaTest, "-u", s"test-results/scala-${scalaVersion.value}", "-o"),
Test / testOptions += Tests
.Argument(TestFrameworks.ScalaTest, "-u", s"test-results/scala-${scalaVersion.value}", "-o"),
concurrentRestrictions in Global := List(Tags.limit(Tags.Test, 4)),
// Copy unit test resources https://groups.google.com/d/topic/play-framework/XD3X6R-s5Mc/discussion
Test / unmanagedClasspath += (baseDirectory map { bd => Attributed.blank(bd / "test") }).value,
Expand Down Expand Up @@ -101,7 +103,7 @@ object ProjectSettings {

def application(applicationName: String): Project = {
Project(applicationName, file(applicationName))
.enablePlugins(PlayScala, UniversalPlugin, BuildInfoPlugin)
.enablePlugins(PlayScala, UniversalPlugin, BuildInfoPlugin, JDebPackaging)
.settings(frontendDependencyManagementSettings)
.settings(frontendCompilationSettings)
.settings(frontendTestSettings)
Expand Down
1 change: 1 addition & 0 deletions project/plugins.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ logLevel := Level.Warn
libraryDependencies ++= Seq(
"joda-time" % "joda-time" % "2.12.7",
"org.joda" % "joda-convert" % "2.2.3",
"org.vafer" % "jdeb" % "1.3" artifacts Artifact("jdeb", "jar", "jar"),
)

resolvers ++= Resolver.sonatypeOssRepos("releases")
Expand Down

0 comments on commit 1c8e5e3

Please sign in to comment.