Fixing the docker credentials in maven so that we don't require the docker daemon for CI/CD

This commit is contained in:
Arpit Mohan 2019-10-17 11:55:55 +05:30
parent 9550f6210d
commit 04a8467095
2 changed files with 8 additions and 2 deletions

View File

@ -17,7 +17,6 @@ variables:
SPRING_PROFILES_ACTIVE: test
MAVEN_OPTS: "-Djava.awt.headless=true -Dmaven.repo.local=./.m2/repository"
MAVEN_CLI_OPTS: "--batch-mode --errors --fail-at-end --show-version"
DOCKER_HUB_ACCESS_TOKEN: "8f5085ea-3b04-42bd-8a67-22bca42443c8"
DOCKER_IMAGE_NAME: $CI_REGISTRY/$CI_PROJECT_NAMESPACE/$CI_PROJECT_NAME:$CI_COMMIT_SHORT_SHA
HEROKU_API_KEY: "467e709c-8489-4e26-be07-050030251f3d"
@ -39,9 +38,9 @@ maven-build:
- merge_requests
docker-package:
image: maven:3-jdk-11-slim
stage: package
script:
- docker login -u arpitappsmith -p $DOCKER_HUB_ACCESS_TOKEN
- mvn package -DskipTests -DskipDockerBuild=false
only:
- master

View File

@ -57,6 +57,13 @@
structure of Docker hub. Will move it to Appsmith's org account once that is resolved.
-->
<image>docker.io/arpitappsmith/appsmith-server</image>
<!-- Please define the Docker Hub credentials as environment variables.
In Gitlab, this will be defined under VARIABLES section of CI/CD Settings
-->
<auth>
<username>${env.DOCKER_HUB_USERNAME}</username>
<password>${env.DOCKER_HUB_ACCESS_TOKEN}</password>
</auth>
</to>
<container>
<jvmFlags>