This file contains 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
diff --git a/system-under-test/post-install-scenarios/01_blobstore.groovy b/system-under-test/post-install-scenarios/01_blobstore.groovy | |
index ea8db9d..9dbf852 100644 | |
--- a/system-under-test/post-install-scenarios/01_blobstore.groovy | |
+++ b/system-under-test/post-install-scenarios/01_blobstore.groovy | |
@@ -1,14 +1,15 @@ | |
-import org.sonatype.nexus.blobstore.api.BlobStoreConfiguration | |
import org.sonatype.nexus.blobstore.api.BlobStoreManager | |
import groovy.json.JsonSlurper | |
def object = new JsonSlurper().parseText(args) |
This file contains 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
import org.sonatype.nexus.blobstore.api.BlobStoreConfiguration | |
import org.sonatype.nexus.blobstore.api.BlobStoreManager | |
def blobStoreManager = container.lookup(BlobStoreManager.class.name) | |
blobStoreManager.create(new BlobStoreConfiguration(name: 'default', type: 'Google Cloud Storage', | |
attributes: [ | |
'google cloud storage': [ | |
bucket: "bucket-name-goes-here" // if you use an interpolated Groovy String here, make sure you call toString() | |
] | |
])) |
This file contains 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
/** | |
* Tested with Nexus Repository Manager 3.6. | |
* Warning: uses internal APIs which are subject to change. | |
* | |
* When run, prints a task log entry for each OrientDB database indicating whether or not the database is frozen. | |
* See https://orientdb.com/docs/2.2/Console-Command-Freeze-Db.html | |
* | |
* Usage: | |
* 1. Create a task with the "Execute Script" type - see https://help.sonatype.com/display/NXRM3/Configuration#Configuration-ConfiguringandExecutingTasks | |
* 2. Set task frequency to manual |
This file contains 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
def configuration = new org.sonatype.nexus.repository.config.Configuration() | |
configuration.setAttributes( | |
'maven': [ | |
'versionPolicy': 'RELEASE', | |
'layoutPolicy': 'STRICT' | |
], | |
'proxy': [ | |
'remoteUrl': 'http://localhost:8000', | |
'contentMaxAge': -1, | |
'metadataMaxAge': 1440 |
This file contains 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
import org.sonatype.nexus.common.entity.* | |
import org.sonatype.nexus.security.* | |
import org.sonatype.nexus.security.authz.* | |
import org.sonatype.nexus.selector.* | |
import com.google.common.collect.ImmutableMap | |
// use container.lookup to fetch internal APIs we need to use | |
def selectorManager = container.lookup(SelectorManager.class.name) | |
def securitySystem = container.lookup(SecuritySystem.class.name) |
This file contains 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
import scala.concurrent.duration._ | |
import io.gatling.core.Predef._ | |
import io.gatling.http.Predef._ | |
import io.gatling.jdbc.Predef._ | |
class RecordedSimulation extends Simulation { | |
val httpProtocol = http |
This file contains 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
/** | |
* Reads the version of the artifact from the Spring Boot application.yml. | |
* Depends on the following in build.gradle: | |
<pre> | |
processResources { | |
filesMatching('application.yml') { | |
expand(project.properties) | |
} | |
} | |
</pre> |
This file contains 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
/** | |
* Reads the version of the artifact from the MANIFEST. | |
* Depends on actually setting version in MANIFEST; Gradle snippet below: | |
<pre> | |
jar { | |
manifest { | |
attributes( | |
'Implementation-Title': project.name, | |
'Implementation-Version': project.version | |
) |
This file contains 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
plugins { | |
id 'com.craigburke.bower-installer' version '2.5.1' | |
} | |
bower { | |
installBase = 'src/main/resources/static/bower_components' | |
// any changes to bower dependencies must also be manually copied to src/main/resources/bower.json | |
'angular'('~1.5.5') { | |
source 'angular.min.js' | |
} | |
'angular-animate'('~1.5.5') { |
This file contains 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
/** | |
* Task executed by Jenkins on merges to master to confirm that we appropriately track the last | |
* released version. | |
* Typical commands executed by this Jenkins job, in order: | |
* 1. gradlew clean updateProjectLast | |
* 2. git commit -am "Tracking last released version" | |
* 3. gradlew bootRepackage uploadArchives | |
*/ | |
task updateProjectLast() { | |
doLast { |
NewerOlder