seira 0.9.0 → 0.9.2

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: 5308da7fa9f186ee201c09b028df22b1b55adf32908bff5b01af79cbebb5ebb9
4
- data.tar.gz: 0b51dbcc1ea03797265ec75cae09eeef3a530a4d0822236087fc134c57944d8b
3
+ metadata.gz: bcb71602621b522d12285dbeb5e752dcedbc246b4d490726fdaa61a5d3441579
4
+ data.tar.gz: ded0a32bb25d7df60741c76b93b8b8622dd10389edb324e83d2299e2aed43e56
5
5
  SHA512:
6
- metadata.gz: 32920e089d26ca317373a577827393fc5ec276b80546cae3cb306606b9f531c51cb9aec818caebe7dfbcbf0d2ede6e71059d5cfaeb127a22d2eef06377c8c493
7
- data.tar.gz: cba266956e025a7fea94a634f049215304788f3e09ba6880b810fb391653d508fe166249e9a45b97a4567c096386e1d48eb74fc80ef19b3b397418d8bf0f37cd
6
+ metadata.gz: dd862ede0cc26ca23eb684f8b962e461b96c975b9ec09dbc314e15e7e2db6e51622da989f12ac7ff4baab3f73ad5dc0de3b201cf2cbb23fbfd13ee6ab6e2f12d
7
+ data.tar.gz: 1b9b00330a3a1e0fde8472c0c9cccbbeac266f85c39badf210a06686136845d94db0f2e3b12a767a6c9fc6152150d59ccc9f491ad3bff5fb9db6cc3afeebff73
@@ -0,0 +1,36 @@
1
+ name: Package Seira Gem
2
+
3
+ on:
4
+ push:
5
+ tags:
6
+ - "*"
7
+
8
+ jobs:
9
+ build:
10
+ name: Build + Publish
11
+ runs-on: ubuntu-latest
12
+ permissions:
13
+ contents: read
14
+ packages: write
15
+
16
+ steps:
17
+ - uses: actions/checkout@v3
18
+ - name: Set up Ruby 2.7.7
19
+ # To automatically get bug fixes and new Ruby versions for ruby/setup-ruby,
20
+ # change this to (see https://github.com/ruby/setup-ruby#versioning):
21
+ # uses: ruby/setup-ruby@v1
22
+ uses: ruby/setup-ruby@55283cc23133118229fd3f97f9336ee23a179fcf # v1.146.0
23
+ with:
24
+ ruby-version: 2.7.7
25
+
26
+ - name: Publish to GPR
27
+ run: |
28
+ mkdir -p $HOME/.gem
29
+ touch $HOME/.gem/credentials
30
+ chmod 0600 $HOME/.gem/credentials
31
+ printf -- "---\n:github: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials
32
+ gem build seira.gemspec
33
+ export RELEASE_VER=$(bundle exec ruby -e 'require "seira"; puts Seira::VERSION')
34
+ gem push --KEY github --host https://rubygems.pkg.github.com/joinhandshake seira-"${RELEASE_VER}".gem
35
+ env:
36
+ GEM_HOST_API_KEY: "Bearer ${{secrets.PACKAGES_TOKEN}}" # Apparently GITHUB_TOKEN is supposed to work here, but it doesn't. Even with the permissions set under jobs.build.permissions.
data/.trunk/trunk.yaml CHANGED
@@ -15,7 +15,6 @@ runtimes:
15
15
  lint:
16
16
  enabled:
17
17
  - actionlint@1.6.25
18
- - checkov@2.4.6
19
18
  - git-diff-check
20
19
  - markdownlint@0.35.0
21
20
  - prettier@3.0.2
@@ -23,8 +22,9 @@ lint:
23
22
  - shfmt@3.6.0
24
23
  - trivy@0.44.1
25
24
  - trufflehog@3.48.0
26
- - yamllint@1.32.0
27
25
  disabled:
26
+ - checkov@2.4.6
27
+ - yamllint@1.32.0
28
28
  - rubocop@1.39.0
29
29
  actions:
30
30
  enabled:
data/README.md CHANGED
@@ -116,28 +116,28 @@ All functionality is targeted to be a platform on top of Kubernetes that has a H
116
116
 
117
117
  ### App
118
118
 
119
- * Bootstrap new applications
120
- * Apply new configurations to an application
121
- * Scale app tiers
122
- * Restart an application
119
+ - Bootstrap new applications
120
+ - Apply new configurations to an application
121
+ - Scale app tiers
122
+ - Restart an application
123
123
 
124
124
  ### Database (Postgres)
125
125
 
126
- * List postgres instances
127
- * Create new primary and automatically set the right secrets with configurability such as HA, CPU, Memory.
128
- * Create a new replica on the primary
129
- * Pgbouncer yaml generation for all new instances
130
- * Delete an instance
126
+ - List postgres instances
127
+ - Create new primary and automatically set the right secrets with configurability such as HA, CPU, Memory.
128
+ - Create a new replica on the primary
129
+ - Pgbouncer yaml generation for all new instances
130
+ - Delete an instance
131
131
 
132
132
  ### Pods
133
133
 
134
- * List pods for a given app
135
- * Connect to a running pod to run commands
136
- * Run a one-off command such as `rails db:migrate`
134
+ - List pods for a given app
135
+ - Connect to a running pod to run commands
136
+ - Run a one-off command such as `rails db:migrate`
137
137
 
138
138
  ### Secrets
139
139
 
140
- * List, set, unset secrets
140
+ - List, set, unset secrets
141
141
 
142
142
  ## Example Usage
143
143
 
@@ -173,6 +173,10 @@ After checking out the repo, run `bin/setup` to install dependencies. Then, run
173
173
 
174
174
  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).
175
175
 
176
+ ## Packages
177
+
178
+ A Github acions workflow will build and push a new release to Github packages on on new tags. You can cut a new release using `./bin/release` to push a new tag and trigger a release.
179
+
176
180
  ## Contributing
177
181
 
178
182
  Bug reports and pull requests are welcome on GitHub at https://github.com/joinhandshake/seira.
@@ -185,8 +189,6 @@ Future roadmap has plans for:
185
189
  - More functionality for managing pods
186
190
  - More seamless `seira setup` script
187
191
 
188
-
189
192
  ## License
190
193
 
191
194
  The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
192
-
data/bin/release ADDED
@@ -0,0 +1,22 @@
1
+ #! /usr/bin/env bash
2
+
3
+ version=$(bundle exec ruby -e 'require "seira"; puts Seira::VERSION')
4
+ branch=$(git rev-parse --abbrev-ref HEAD)
5
+
6
+ version_tag="v${version}"
7
+
8
+ git fetch origin --tags
9
+
10
+ if [[ ${branch} != "main" ]]; then
11
+ echo "You must be on the main branch to release"
12
+ exit 1
13
+ fi
14
+
15
+ # shellcheck disable=SC2312
16
+ if git tag | grep -q "${version_tag}"; then
17
+ echo "Tag ${version_tag} already exists"
18
+ exit 1
19
+ fi
20
+
21
+ echo git tag "${verison_tag}"
22
+ echo git push origin "${version_tag}"
data/lib/seira/pods.rb CHANGED
@@ -151,6 +151,7 @@ module Seira
151
151
  # for a simple terminal pod it's fine
152
152
  spec['containers'].each do |container|
153
153
  container['command'] = %w[sleep 86400] # 86400 seconds = 24 hours
154
+ container.delete('args')
154
155
  end
155
156
 
156
157
  puts 'Creating dedicated pod...'
data/lib/seira/version.rb CHANGED
@@ -1,4 +1,4 @@
1
1
  module Seira
2
- VERSION = "0.9.0".freeze
2
+ VERSION = "0.9.2".freeze
3
3
  end
4
4
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: seira
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.0
4
+ version: 0.9.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Scott Ringwelski
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-04-16 00:00:00.000000000 Z
11
+ date: 2024-04-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: highline
@@ -102,6 +102,7 @@ executables:
102
102
  extensions: []
103
103
  extra_rdoc_files: []
104
104
  files:
105
+ - ".github/workflows/package-seira-gem.yml"
105
106
  - ".github/workflows/ruby.yml"
106
107
  - ".github/workflows/trunk.yml"
107
108
  - ".gitignore"
@@ -118,6 +119,7 @@ files:
118
119
  - README.md
119
120
  - Rakefile
120
121
  - bin/console
122
+ - bin/release
121
123
  - bin/seira
122
124
  - bin/setup
123
125
  - lib/helpers.rb