handsome_fencer-circle_c_i 0.1.27 → 0.1.28

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 3640fcbee6b490771f6cc8ea3927f87313b190d98ee1189eadb42626e82b2c8f
4
- data.tar.gz: 2fc0aa33e8e2700b1a6003b4cb33b7b2335b77422154212ffe025b75d88168d2
3
+ metadata.gz: bc930517fb1fc9626fdcf832e02c73d2428246c6e52ef6e34cbf51c398c6b409
4
+ data.tar.gz: ec1a10710cf37e6ee66ca118ceb5703373a23439688f3637917fc1c781a01c94
5
5
  SHA512:
6
- metadata.gz: e1ce87feaba8ea3516ae5f8ffe6b51f4adf415f78ea505c345134dd23dc8dbbd68bcaf336f6e406ee604afce127f337874901d41446eeb2f84502ef5bb934de3
7
- data.tar.gz: 16862e84d722f8212640280dbff83b5173917af90ad8da073c01ee72483e66f7c2957a476b5d941c53c34efa2e249a5c8ed13aad13906ca7fb9e66652925cef1
6
+ metadata.gz: 0a07ef7638a2adab5cc7e191bf3b7cfaa7c01b5dcc51eeef645c35550f78b54fe542e22927ad6beef0798fe2e8b1f58f4db088f17e571fcc397b1fc95d6ac4f6
7
+ data.tar.gz: 27a620fec97b85b384377f71ab4ab151eec129695ee60fe07ca2338b059a6e1c47af4c1ba2dc6c2072b778aa2233fff01c70a8968939f756ccfadeba1f9961e2
data/README.md CHANGED
@@ -41,7 +41,7 @@ docker-compose version 1.21.0, build 5920eb0
41
41
  ...You are now ready to either a) greenfield a handsome new app or b) handsomize an existing one.
42
42
 
43
43
 
44
- ## Greenfielding a hanfully dockerized Rails application:
44
+ ## Greenfielding a fully dockerized Rails application:
45
45
 
46
46
  1) Execute the install command:
47
47
 
@@ -9,54 +9,24 @@ jobs:
9
9
  machine: true
10
10
  steps:
11
11
  - checkout
12
- - run: gem install handsome_fencer-circle_c_i
13
- - run: ruby .circleci/expose_env.rb
14
- - run: docker-compose build dev_app database
15
- - run: docker-compose run dev_app bin/rails db:create db:migrate test
16
-
17
- push:
18
- docker:
19
- - image: circleci/ruby:2.5.1-node-browsers
20
- environment:
21
- BASH_ENV: .env/circle/deploy.env
22
- steps:
23
- - checkout
24
- - setup_remote_docker
25
- - run: gem install handsomefencer-environment
26
- - run: ruby expose_env.rb
27
- - run: docker-compose up -d --build
12
+ - add_ssh_keys
13
+ - run: bundle --gemfile='.circleci/Gemfile'
14
+ - run: handsome_fencer-circle_c_i expose development
15
+ - run: handsome_fencer-circle_c_i expose circle
16
+ - run: echo 'source .circleci/circle.env' >> $BASH_ENV
17
+ - run: docker-compose build
18
+ - run: docker-compose up -d
19
+ - run: docker-compose exec app bin/rails db:create db:migrate
20
+ - run: docker login -u $DOCKERHUB_USER -p $DOCKERHUB_PASS
21
+ - run:
22
+ name: Tag app image
23
+ command: docker tag $(docker images | grep project_app | awk '{ print $3 }') ${DOCKERHUB_ORG_NAME}/${APP_NAME}_app:$DEPLOY_TAG
28
24
  - run:
29
25
  name: Tag web image
30
- command: docker tag $(docker images | grep project_web | awk '{ print $3 }') rennmappe/bacchanal_web:$DEPLOY_TAG
31
- - run: docker login -u $DOCKERHUB_USER -p $DOCKERHUB_PASS
32
- - run: docker push rennmappe/bacchanal_web:$DEPLOY_TAG
26
+ command: docker tag $(docker images | grep project_web | awk '{ print $3 }') ${DOCKERHUB_ORG_NAME}/${APP_NAME}_web:$DEPLOY_TAG
33
27
 
34
- deploy:
35
- docker:
36
- - image: circleci/ruby:2.5.1-node-browsers
37
- environment:
38
- BASH_ENV: .env/circle/deploy.env
39
- steps:
40
- - checkout
41
- - add_ssh_keys
42
- - run: bundle install --without production
43
- - run: ruby expose_env.rb
44
- - run: bin/rails docker:deploy
45
28
 
46
- workflows:
47
- version: 2
48
- build-and-deploy:
49
- jobs:
50
- - build
51
- - push:
52
- requires:
53
- - build
54
- filters:
55
- branches:
56
- only: master
57
- - deploy:
58
- requires:
59
- - push
60
- filters:
61
- branches:
62
- only: master
29
+ - run: docker push ${DOCKERHUB_ORG_NAME}/${APP_NAME}_app:$DEPLOY_TAG
30
+ - run: docker push ${DOCKERHUB_ORG_NAME}/${APP_NAME}_web:$DEPLOY_TAG
31
+
32
+ - run: rake --rakefile .circleci/Rakefile
@@ -0,0 +1,62 @@
1
+ defaults: &defaults
2
+ working_directory: /tmp
3
+
4
+ version: 2
5
+
6
+ jobs:
7
+
8
+ build:
9
+ machine: true
10
+ steps:
11
+ - checkout
12
+ - run: gem install handsome_fencer-circle_c_i
13
+ - run: ruby .circleci/expose_env.rb
14
+ - run: docker-compose build dev_app database
15
+ - run: docker-compose run dev_app bin/rails db:create db:migrate test
16
+
17
+ push:
18
+ docker:
19
+ - image: circleci/ruby:2.5.1-node-browsers
20
+ environment:
21
+ BASH_ENV: .env/circle/deploy.env
22
+ steps:
23
+ - checkout
24
+ - setup_remote_docker
25
+ - run: gem install handsomefencer-environment
26
+ - run: ruby expose_env.rb
27
+ - run: docker-compose up -d --build
28
+ - run:
29
+ name: Tag web image
30
+ command: docker tag $(docker images | grep project_web | awk '{ print $3 }') rennmappe/bacchanal_web:$DEPLOY_TAG
31
+ - run: docker login -u $DOCKERHUB_USER -p $DOCKERHUB_PASS
32
+ - run: docker push rennmappe/bacchanal_web:$DEPLOY_TAG
33
+
34
+ deploy:
35
+ docker:
36
+ - image: circleci/ruby:2.5.1-node-browsers
37
+ environment:
38
+ BASH_ENV: .env/circle/deploy.env
39
+ steps:
40
+ - checkout
41
+ - add_ssh_keys
42
+ - run: bundle install --without production
43
+ - run: ruby expose_env.rb
44
+ - run: bin/rails docker:deploy
45
+
46
+ workflows:
47
+ version: 2
48
+ build-and-deploy:
49
+ jobs:
50
+ - build
51
+ - push:
52
+ requires:
53
+ - build
54
+ filters:
55
+ branches:
56
+ only: master
57
+ - deploy:
58
+ requires:
59
+ - push
60
+ filters:
61
+ branches:
62
+ only: master
@@ -5,7 +5,7 @@ services:
5
5
  app:
6
6
  build:
7
7
  context: .
8
- dockerfile: .circleci/containers/app/Dockerfile
8
+ dockerfile: docker/containers/app/Dockerfile
9
9
 
10
10
  depends_on:
11
11
  - database
@@ -16,8 +16,8 @@ services:
16
16
  - .:/usr/src/app
17
17
  - gem_cache:/gems
18
18
  env_file:
19
- - .circleci/containers/database/development.env
20
- - .circleci/containers/app/development.env
19
+ - docker/containers/database/development.env
20
+ - docker/containers/app/development.env
21
21
  command: [ "bin/rails", "s" ]
22
22
 
23
23
  stdin_open: true
@@ -28,7 +28,7 @@ services:
28
28
  database:
29
29
  image: postgres
30
30
  env_file:
31
- - .circleci/containers/database/development.env
31
+ - docker/containers/database/development.env
32
32
 
33
33
  volumes:
34
34
  - database-data:/var/lib/postgresql/data
@@ -1,5 +1,5 @@
1
1
  module HandsomeFencer
2
2
  module CircleCI
3
- VERSION = '0.1.27'
3
+ VERSION = '0.1.28'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: handsome_fencer-circle_c_i
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.27
4
+ version: 0.1.28
5
5
  platform: ruby
6
6
  authors:
7
7
  - schadenfred
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-10-14 00:00:00.000000000 Z
11
+ date: 2018-10-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: sshkit
@@ -66,20 +66,6 @@ dependencies:
66
66
  - - ">="
67
67
  - !ruby/object:Gem::Version
68
68
  version: '0'
69
- - !ruby/object:Gem::Dependency
70
- name: rails
71
- requirement: !ruby/object:Gem::Requirement
72
- requirements:
73
- - - ">="
74
- - !ruby/object:Gem::Version
75
- version: '0'
76
- type: :development
77
- prerelease: false
78
- version_requirements: !ruby/object:Gem::Requirement
79
- requirements:
80
- - - ">="
81
- - !ruby/object:Gem::Version
82
- version: '0'
83
69
  - !ruby/object:Gem::Dependency
84
70
  name: byebug
85
71
  requirement: !ruby/object:Gem::Requirement
@@ -136,6 +122,7 @@ files:
136
122
  - lib/handsome_fencer/circle_c_i/templates/Gemfile
137
123
  - lib/handsome_fencer/circle_c_i/templates/Gemfile.lock
138
124
  - lib/handsome_fencer/circle_c_i/templates/circleci/config.yml
125
+ - lib/handsome_fencer/circle_c_i/templates/circleci/config.yml.workflow-example
139
126
  - lib/handsome_fencer/circle_c_i/templates/config/database.yml
140
127
  - lib/handsome_fencer/circle_c_i/templates/docker-compose.yml
141
128
  - lib/handsome_fencer/circle_c_i/templates/docker/containers/app/Dockerfile