I'm using the Spring Boot Gradle plugin to build and push Docker images to a remote Docker registry
bootBuildImage {
imageName = "docker-repo/app-name"
publish = true
docker {
publishRegistry {
username = project.property('repoUsername')
password = project.property('repoPassword')
}
}
}
The Docker repository credentials are stored in ~/.gradle/gradle.properties.
Is this secure? Would I need to store a similar ~/.gradle/gradle.properties file in the CI/CD environment?
What are the best approaches from a security perspective?