scc_rails 0.1.0 → 0.1.1
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 +4 -4
- data/README.md +9 -2
- data/app/controllers/scc_rails/application_controller.rb +2 -2
- data/lib/scc_rails/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 54cd5e341ee1b7f3f11f95df3a7f1938a6d1aeb4a4864fb7eff1ef211245708e
|
4
|
+
data.tar.gz: 59c76203a17738d2db7a7ec5b966217c900229878264be8fbf1022aaa37c8db3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 64d8289a87fae2dfe97456e60a1205b54e8f2b575c7445ccaa75a9e8dad11414ee4894305f658281bf46d709e09d317f9c9152aadeeae277e8f81060e9699172
|
7
|
+
data.tar.gz: 13d8a5aadf591a14b6e142f32f2590fff6ef75d1597405a4f39ed152ce6e74443b85c1833e3616fe319073f6008dfff84a50547de8da43e5d97976c1e21d2299
|
data/README.md
CHANGED
@@ -1,8 +1,15 @@
|
|
1
1
|
# SccRails
|
2
|
-
|
2
|
+
|
3
|
+
Spring cloud config client integration with rails, use scc_ruby, just use `$cloud_env`.
|
3
4
|
|
4
5
|
## Usage
|
5
|
-
|
6
|
+
|
7
|
+
```ruby
|
8
|
+
# routes.rb
|
9
|
+
mount SccRails::Engine => '/scc'
|
10
|
+
```
|
11
|
+
|
12
|
+
and then you can use `curl 127.0.0.1:3000/scc/refresh` to refresh `$cloud_env`
|
6
13
|
|
7
14
|
## Installation
|
8
15
|
Add this line to your application's Gemfile:
|
@@ -1,6 +1,6 @@
|
|
1
1
|
module SccRails
|
2
|
-
class ApplicationController < ActionController::
|
3
|
-
|
2
|
+
class ApplicationController < ActionController::Base
|
3
|
+
http_basic_authenticate_with name: ENV['SCC_USERNAME'], password: ENV['SCC_PASSWORD'], only: :refresh
|
4
4
|
|
5
5
|
def refresh
|
6
6
|
SccRails::Engine.reload_config
|
data/lib/scc_rails/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: scc_rails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- FlowerWrong
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-03-
|
11
|
+
date: 2019-03-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|