PromucFlow_constructor/app/server/.gitlab-ci.yml
Trisha Anand 73757c3425 Merge branch 'release' into feature/acl-spring-object
# Conflicts:
#	.gitignore
#	appsmith-plugins/mongoPlugin/plugin.properties
#	appsmith-plugins/postgresPlugin/plugin.properties
#	appsmith-plugins/rapidApiPlugin/plugin.properties
#	appsmith-plugins/restApiPlugin/plugin.properties
#	appsmith-plugins/restApiPlugin/src/main/java/com/external/plugins/RestApiPlugin.java
#	appsmith-server/src/main/java/com/appsmith/server/constants/FieldName.java
#	appsmith-server/src/main/java/com/appsmith/server/repositories/ActionRepository.java
#	appsmith-server/src/main/java/com/appsmith/server/services/ActionServiceImpl.java
#	appsmith-server/src/main/java/com/appsmith/server/services/DatasourceContextServiceImpl.java
#	appsmith-server/src/main/java/com/appsmith/server/services/DatasourceServiceImpl.java
#	appsmith-server/src/test/java/com/appsmith/server/services/ActionServiceTest.java
#	appsmith-server/src/test/java/com/appsmith/server/services/ApplicationServiceTest.java
#	appsmith-server/src/test/java/com/appsmith/server/services/LayoutServiceTest.java
#	appsmith-server/src/test/java/com/appsmith/server/services/PageServiceTest.java
#	build.sh
2020-06-12 19:14:31 +05:30

89 lines
2.3 KiB
YAML

.only-default: &only-default
only:
- release
- master
- merge_requests
image: docker:latest
cache:
paths:
- ./.m2/repository
variables:
DOCKER_DRIVER: overlay2
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_IMAGE_NAME: $CI_REGISTRY/$CI_PROJECT_NAMESPACE/$CI_PROJECT_NAME:$CI_COMMIT_SHORT_SHA
# Instruct Testcontainers to use the daemon of DinD.
DOCKER_HOST: "tcp://docker:2375"
stages:
- build
- package
- deploy
maven-build:
image: maven:3-jdk-11-slim
stage: build
services:
- redis
- docker:dind
script:
- mvn package -B -Dspring.profiles.active=$SPRING_PROFILES_ACTIVE
artifacts:
paths:
- appsmith-server/target/*.jar
- appsmith-plugins/*/target/*.jar
only:
- release
- master
- merge_requests
- feature/acl-spring-object
docker-package:
image: docker:dind
services:
- docker:19.03.5-dind #change this back to docker-dind
stage: package
script:
- docker build -t appsmith/appsmith-server:release .
- docker login -u $DOCKER_HUB_USERNAME -p $DOCKER_HUB_ACCESS_TOKEN
- docker push appsmith/appsmith-server:release
only:
- release
docker-package-master:
image: docker:dind
services:
- docker:19.03.5-dind #change this back to docker-dind
stage: package
script:
- docker build -t appsmith/appsmith-server:latest .
- docker build -t appsmith/appsmith-server:$CI_COMMIT_SHORT_SHA .
- docker login -u $DOCKER_HUB_USERNAME -p $DOCKER_HUB_ACCESS_TOKEN
# If we don't add the tag to the `docker push` command, all the tags for this image will be pushed
- docker push appsmith/appsmith-server
only:
- master
docker-package-acl:
image: docker:dind
services:
- docker:19.03.5-dind #change this back to docker-dind
stage: package
script:
- docker build -t appsmith/appsmith-server:acl .
- docker login -u $DOCKER_HUB_USERNAME -p $DOCKER_HUB_ACCESS_TOKEN
- docker push appsmith/appsmith-server:acl
only:
- feature/acl-spring-object
heroku-deploy:
stage: deploy
image: tmaier/dpl:latest
script:
- dpl --provider=heroku --app=appsmith-test --api-key=$HEROKU_API_KEY
only:
- release