Skip to content

Commit

Permalink
Merge pull request openssl#25 from ruby/docker
Browse files Browse the repository at this point in the history
Run tests under ruby-openssl-docker container
  • Loading branch information
Zachary Scott committed Sep 1, 2015
2 parents 2e3e2d1 + 2f8b9f1 commit 8403e1c
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 12 deletions.
26 changes: 14 additions & 12 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,17 @@
language: c
sudo: required
services:
- docker
before_install:
- "ruby -ropenssl -e 'puts OpenSSL::OPENSSL_VERSION'"
- "gem update rubygems-update"
- "gem update --system"
- "gem update bundler"
script: "bundle exec rake test"

rvm:
- 2.2
- ruby-head

- sudo apt-get -qq update
install:
- sudo sh -c "curl -L https://github.com/docker/compose/releases/download/1.3.3/docker-compose-`uname -s`-`uname -m` > /usr/local/bin/docker-compose"
- sudo chmod +x /usr/local/bin/docker-compose
script:
- docker-compose run test
matrix:
allow_failures:
- rvm: ruby-head
include:
- env: RUBY_VERSION=2.2.2 OPENSSL_VERSION=1.0.0s
- env: RUBY_VERSION=2.2.2 OPENSSL_VERSION=1.0.1p
- env: RUBY_VERSION=2.2.2 OPENSSL_VERSION=1.0.2d
fast_finish: true
1 change: 1 addition & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
FROM zzak/ruby-openssl-docker
1 change: 1 addition & 0 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,5 @@ Rake::ExtensionTask.new('openssl')
# the same as before
Rake::TestTask.new do |t|
t.libs << 'test'
t.warning = true
end
14 changes: 14 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
compile: &defaults
build: .
volumes:
- .:/home/openssl/code:rw
environment:
RUBY_VERSION:
OPENSSL_VERSION:
command: bundle exec rake compile
test:
<<: *defaults
command: bundle exec rake test
shell:
<<: *defaults
command: bundle exec irb

0 comments on commit 8403e1c

Please sign in to comment.