whoamid 0.0.1 → 0.1.0

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: b704e65a51374bfe3f7c40790d822c8ea00801751d682f516a3f3e454bbd9e7c
4
- data.tar.gz: b356ffa065187e7e8b5f4adbca81094a90dc91458c04a3837e6dc246948e0fee
3
+ metadata.gz: 2daad169846d79aad0b657798efc1960d86bd459e6d55c470577085608631b67
4
+ data.tar.gz: a5af96bca8991427282ae9cf8db4a195196ff68c367bdfbfab1b23bb7878d6c8
5
5
  SHA512:
6
- metadata.gz: d924bea8347952801e95ef163fb6de8e59396ad05558e906ba9d34fdb26259a5c889fe83d69361304fb30ae22a0f5e926fbec17fd95d2ef0c99e4fe54257798e
7
- data.tar.gz: f7962eb63759acdc082aac3d3e720e816986648a8bc4396e08ba3a01f01cee60f30c393b0199b52e7dce243f184b8850770b5c48e78656b7b528e3d34391a793
6
+ metadata.gz: 81808af6f0f67c5b09eef8d3db0289c9be3cb902ee8c795a7fb282703ba08c0c8a13b90a4b297c712502d931a3094dfe983cd52f630f239bb929462f4b8c183b
7
+ data.tar.gz: b8819aca9457435b87859e199f0aeedbbedf24cd295638eae7e5df5e3343b9ed9e320a1fb12d99df69d9ca3c186a0f910b632e6209e528eccc1fbc07d9c51f38
data/.gcloudignore ADDED
@@ -0,0 +1,2 @@
1
+ !.git
2
+ #!include:.gitignore
data/.travis.yml CHANGED
@@ -1,7 +0,0 @@
1
- ---
2
- sudo: false
3
- language: ruby
4
- cache: bundler
5
- rvm:
6
- - 2.5.3
7
- before_install: gem install bundler -v 1.16.6
data/Dockerfile ADDED
@@ -0,0 +1,11 @@
1
+ FROM mattipaksula/gem2exe as builder
2
+
3
+ WORKDIR /gem
4
+ COPY . .
5
+ RUN gem2exe local whoamid
6
+
7
+ #---------------
8
+ FROM ubuntu:18.04
9
+ COPY --from=builder /gem/whoamid /usr/local/bin
10
+
11
+ ENTRYPOINT [ "/usr/local/bin/whoamid" ]
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- whoamid (0.0.1)
4
+ whoamid (0.1.0)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
data/README.md CHANGED
@@ -1,39 +1,3 @@
1
- # Whoamid
1
+ # whoamid
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/whoamid`. 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
6
-
7
- ## Installation
8
-
9
- Add this line to your application's Gemfile:
10
-
11
- ```ruby
12
- gem 'whoamid'
13
- ```
14
-
15
- And then execute:
16
-
17
- $ bundle
18
-
19
- Or install it yourself as:
20
-
21
- $ gem install whoamid
22
-
23
- ## Usage
24
-
25
- TODO: Write usage instructions here
26
-
27
- ## Development
28
-
29
- After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
30
-
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).
32
-
33
- ## Contributing
34
-
35
- Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/whoamid.
36
-
37
- ## License
38
-
39
- The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
3
+ gcloud builds submit --machine-type n1-highcpu-32 --async
data/cloudbuild.yaml ADDED
@@ -0,0 +1,10 @@
1
+ #https://cloud.google.com/cloud-build/docs/build-config
2
+ #https://github.com/GoogleCloudPlatform/cloud-builders-community
3
+ #https://github.com/GoogleContainerTools/kaniko/blob/master/README.md
4
+ substitutions:
5
+
6
+ steps:
7
+ - name: gcr.io/kaniko-project/executor:latest
8
+ args:
9
+ - --cache=true
10
+ - --destination=us.gcr.io/$PROJECT_ID/whoamid:latest
@@ -0,0 +1,14 @@
1
+ version: '3.7'
2
+
3
+ services:
4
+ whoamid:
5
+ image: gem2exe
6
+ volumes:
7
+ - .:/whoamid
8
+ - ./tmp:/build
9
+ - whoamid_cache:/cache
10
+ command: local --path /whoamid --cache-dir /cache --out /build/whoamid whoamid
11
+
12
+ volumes:
13
+ whoamid_cache:
14
+ external: true
@@ -18,6 +18,11 @@ module Whoamid
18
18
  res.body = ENV["HOSTNAME"]
19
19
  end
20
20
 
21
+ server.mount_proc '/sleep' do |req,res|
22
+ sleep req.query_string.to_i
23
+ res.body = ENV["HOSTNAME"]
24
+ end
25
+
21
26
  server.start
22
27
  end
23
28
  end
@@ -1,3 +1,3 @@
1
1
  module Whoamid
2
- VERSION = "0.0.1"
2
+ VERSION = "0.1.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: whoamid
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matti Paksula
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-01-20 00:00:00.000000000 Z
11
+ date: 2019-01-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -60,9 +60,11 @@ executables:
60
60
  extensions: []
61
61
  extra_rdoc_files: []
62
62
  files:
63
+ - ".gcloudignore"
63
64
  - ".gitignore"
64
65
  - ".rspec"
65
66
  - ".travis.yml"
67
+ - Dockerfile
66
68
  - Gemfile
67
69
  - Gemfile.lock
68
70
  - LICENSE.txt
@@ -70,6 +72,8 @@ files:
70
72
  - Rakefile
71
73
  - bin/console
72
74
  - bin/setup
75
+ - cloudbuild.yaml
76
+ - docker-compose.yml
73
77
  - exe/whoamid
74
78
  - lib/whoamid.rb
75
79
  - lib/whoamid/server.rb