first commit
Some checks failed
Vulhub Format Check and Lint / format-check (push) Has been cancelled
Vulhub Format Check and Lint / markdown-check (push) Has been cancelled
Vulhub Docker Image CI / longtime-images-test (push) Has been cancelled
Vulhub Docker Image CI / images-test (push) Has been cancelled
Some checks failed
Vulhub Format Check and Lint / format-check (push) Has been cancelled
Vulhub Format Check and Lint / markdown-check (push) Has been cancelled
Vulhub Docker Image CI / longtime-images-test (push) Has been cancelled
Vulhub Docker Image CI / images-test (push) Has been cancelled
This commit is contained in:
11
base/jenkins/2.441/Dockerfile
Normal file
11
base/jenkins/2.441/Dockerfile
Normal file
@@ -0,0 +1,11 @@
|
||||
FROM jenkins/jenkins:2.441-slim
|
||||
|
||||
LABEL maintainer="phithon <root@leavesongs.com>"
|
||||
|
||||
ENV JAVA_OPTS="-Djenkins.install.runSetupWizard=false"
|
||||
|
||||
USER root
|
||||
RUN set -ex \
|
||||
&& sed -i 's/suspend=y/suspend=n/g' /usr/local/bin/jenkins.sh
|
||||
|
||||
COPY init.groovy /usr/share/jenkins/ref/init.groovy.d
|
15
base/jenkins/2.441/init.groovy
Normal file
15
base/jenkins/2.441/init.groovy
Normal file
@@ -0,0 +1,15 @@
|
||||
#!groovy
|
||||
|
||||
import jenkins.model.*
|
||||
import hudson.security.*
|
||||
import jenkins.security.s2m.AdminWhitelistRule
|
||||
|
||||
def instance = Jenkins.getInstance()
|
||||
|
||||
def hudsonRealm = new HudsonPrivateSecurityRealm(false)
|
||||
hudsonRealm.createAccount("admin", "vulhub")
|
||||
instance.setSecurityRealm(hudsonRealm)
|
||||
|
||||
def strategy = new FullControlOnceLoggedInAuthorizationStrategy()
|
||||
instance.setAuthorizationStrategy(strategy)
|
||||
instance.save()
|
Reference in New Issue
Block a user