未验证 提交 c0f6f91b 编写于 作者: D Dejan Mijić 提交者: GitHub

Run redis container in CI (#23)

上级 7874cbdf
...@@ -16,7 +16,7 @@ machine_ubuntu: &machine_ubuntu ...@@ -16,7 +16,7 @@ machine_ubuntu: &machine_ubuntu
machine: machine:
image: ubuntu-1604:201903-01 image: ubuntu-1604:201903-01
install_jdk: &install_jdk install_deps: &install_jdk
- run: - run:
name: Install JDK name: Install JDK
command: | command: |
...@@ -58,10 +58,10 @@ save_cache: &save_cache ...@@ -58,10 +58,10 @@ save_cache: &save_cache
- save_cache: - save_cache:
key: sbt-zio-redis-cache key: sbt-zio-redis-cache
paths: paths:
- "~/.ivy2/cache" - "~/.ivy2/cache"
- "~/.sbt" - "~/.sbt"
- "~/.m2" - "~/.m2"
- "~/.cache" - "~/.cache"
filter_tags: &filter_tags filter_tags: &filter_tags
tags: tags:
...@@ -90,6 +90,9 @@ test: &test ...@@ -90,6 +90,9 @@ test: &test
- checkout - checkout
- <<: *load_cache - <<: *load_cache
- <<: *install_jdk - <<: *install_jdk
- run:
name: Run Redis
command: docker run -d redis:5-alpine
- run: - run:
name: Run tests name: Run tests
command: ./sbt ++${SCALA_VERSION}! test command: ./sbt ++${SCALA_VERSION}! test
...@@ -97,23 +100,23 @@ test: &test ...@@ -97,23 +100,23 @@ test: &test
release: &release release: &release
steps: steps:
- checkout - checkout
- run: - run:
name: Fetch git tags name: Fetch git tags
command: git fetch --tags command: git fetch --tags
- <<: *load_cache - <<: *load_cache
- run: - run:
name: Write sonatype credentials name: Write sonatype credentials
command: echo "credentials += Credentials(\"Sonatype Nexus Repository Manager\", \"oss.sonatype.org\", \"${SONATYPE_USER}\", \"${SONATYPE_PASSWORD}\")" > ~/.sbt/1.0/sonatype.sbt command: echo "credentials += Credentials(\"Sonatype Nexus Repository Manager\", \"oss.sonatype.org\", \"${SONATYPE_USER}\", \"${SONATYPE_PASSWORD}\")" > ~/.sbt/1.0/sonatype.sbt
- run: - run:
name: Write PGP public key name: Write PGP public key
command: echo -n "${PGP_PUBLIC}" | base64 -di > /tmp/public.asc command: echo -n "${PGP_PUBLIC}" | base64 -di > /tmp/public.asc
- run: - run:
name: Write PGP secret key name: Write PGP secret key
command: echo -n "${PGP_SECRET}" | base64 -di > /tmp/secret.asc command: echo -n "${PGP_SECRET}" | base64 -di > /tmp/secret.asc
- run: - run:
name: Release artifacts name: Release artifacts
command: ./sbt ++${SCALA_VERSION}! ci-release command: ./sbt ++${SCALA_VERSION}! ci-release
jobs: jobs:
lint: lint:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册