Skip to content

Commit

Permalink
Merge pull request #1963 from hung-nguyen-hoang/DC-3240-Ext
Browse files Browse the repository at this point in the history
DC-3240: Fixing get ruby gem api key from environment

Reviewed-by: https://github.com/danh-ung
  • Loading branch information
gdgate authored Mar 12, 2024
2 parents d3a9860 + 6e4a92b commit e5c72ff
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,12 @@ jobs:
restore-keys: ${{ runner.os }}-m2
- name: Run gem release
run: |
mkdir -p ~/.gem
echo -e "---\n:rubygems_api_key: ${{ secrets.RUBYGEMS_API_KEY }}" > ~/.gem/credentials
chmod 0600 ~/.gem/credentials
echo ${SAMPLE_KEY:0:3}
echo ${GEM_HOST_API_KEY:0:20}
bundle exec rake gem:release
env:
SAMPLE_KEY: "a1234567"
GEM_HOST_API_KEY: ${{ secrets.RUBYGEMS_API_KEY }}
rubygems-release:
runs-on: ubuntu-latest
steps:
Expand All @@ -40,10 +42,12 @@ jobs:
bundler-cache: true
- name: Run gem release
run: |
mkdir -p ~/.gem
echo -e "---\n:rubygems_api_key: ${{ secrets.RUBYGEMS_API_KEY }}" > ~/.gem/credentials
chmod 0600 ~/.gem/credentials
echo ${SAMPLE_KEY:0:3}
echo ${GEM_HOST_API_KEY:0:20}
bundle exec rake gem:release
env:
SAMPLE_KEY: "a1234567"
GEM_HOST_API_KEY: ${{ secrets.RUBYGEMS_API_KEY }}
gem-smoke-test:
runs-on: ubuntu-latest
needs: [jruby-gem-release, rubygems-release]
Expand Down

0 comments on commit e5c72ff

Please sign in to comment.