dockerci 0.1.1 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: bd838db09b444ae34d5ccf6f2ddd4c036967fbd18e4c80a0a3c1d9673739e97b
4
- data.tar.gz: 44e82e970a32ba52a68dd8324ae26531dd91e08dc8b7540a138460da590451bf
3
+ metadata.gz: 2cbb44855a1cf883bbfa2bccaa727e4f1359659d3014e3bb90eedbab3cdae150
4
+ data.tar.gz: 1db9059ad7c5cc2584485595beb1a53f11b2fafb1b683cb96fe718cd4bd522ed
5
5
  SHA512:
6
- metadata.gz: 803e04142a58d636c4ef8dff9871fe1b9779892b854962107b242c36385d661621ecedb6e3076950901632a3eb841b917fa620f2d5092e6a41cde864a0bdec64
7
- data.tar.gz: fc2f7f786c62ec6d6e739e0927b1b3092d9f6afc6ef4fba5d9c82eccc91b75f0980f4e7eb054b0d3ff5d624855cdb9d5858cf91a6352a3ef0090bd88d8f548c7
6
+ metadata.gz: 0d56d6815267562ae3d862ec9acbebec7bae272e685d6a43b302392d6647124e9591d618d4dbba5e689f1c48c8e8da2688084b301c02a0eca276c370717abff5
7
+ data.tar.gz: fb76a33333a0988eac3eb119ed3dd9d260c0d0779f257e8c087b79340ef0e572d0e954472260e63702f3a9d8cbe3092c88efe179bc97ae1f77268665a7b17528
data/README.md CHANGED
@@ -1,8 +1,6 @@
1
1
  # Dockerci
2
2
 
3
- Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/dockerci`. To experiment with that code, run `bin/console` for an interactive prompt.
4
-
5
- TODO: Delete this and the text above, and describe your gem
3
+ Read configuration of `config/database.yml`, use that information to launch a circleci mysql docker image.
6
4
 
7
5
  ## Installation
8
6
 
@@ -22,14 +20,20 @@ Or install it yourself as:
22
20
 
23
21
  ## Usage
24
22
 
25
- TODO: Write usage instructions here
23
+ Simply run:
24
+
25
+ ```terminal
26
+ bundle exec rake dockerci:mysql
27
+ ```
26
28
 
27
- ## Development
29
+ It will load your env's database.yml, and using that information, launches the circleci/mysql image.
28
30
 
29
- After checking out the repo, run `bin/setup` to install dependencies. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
31
+ If you want to specify the launching version, then in your `config/application.rb`, put following code:
30
32
 
31
- To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
33
+ ```ruby
34
+ config.dockerci_mysql_version = '5.7'
35
+ ```
32
36
 
33
37
  ## Contributing
34
38
 
35
- Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/dockerci.
39
+ Bug reports and pull requests are welcome on GitHub at https://github.com/Yuki-Inoue/dockerci.
@@ -8,7 +8,8 @@ namespace :dockerci do
8
8
  cmd += ['--name', db_name]
9
9
  cmd += ['-e', "MYSQL_DATABASE=#{db_name}"]
10
10
  img_name = 'circleci/mysql'
11
- tag = Rails.application.config.dockerci_mysql_version
11
+ tag = Rails.application.config.dockerci_mysql_version ||
12
+ ENV['DOCKERCI_MYSQL_VERSION']
12
13
  img_name += ':' + tag if tag
13
14
  cmd << img_name
14
15
  exec(*cmd)
@@ -1,3 +1,3 @@
1
1
  module Dockerci
2
- VERSION = "0.1.1"
2
+ VERSION = "0.2.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dockerci
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Yuki INOUE
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-04-03 00:00:00.000000000 Z
11
+ date: 2019-07-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: railties