Skip to content

Commit

Permalink
Merge pull request #801 from WGBH-MLA/fix-build
Browse files Browse the repository at this point in the history
Remove reliance on DEPENDENCIES_NEXT
  • Loading branch information
orangewolf authored Dec 12, 2023
2 parents 3790c89 + 29e5cae commit dd521da
Show file tree
Hide file tree
Showing 14 changed files with 12 additions and 416 deletions.
158 changes: 5 additions & 153 deletions .github/workflows/build-test-lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ jobs:
echo ${HEAD_TAG::8}
env:
HEAD_TAG: ${{ github.event.pull_request.head.sha || github.sha }}
SE_NODE_SESSION_TIMEOUT: 999999
shell: bash
- name: Downcase repo
run: echo "REPO_LOWER=${REPO,,}" >> $GITHUB_ENV
Expand Down Expand Up @@ -131,6 +132,10 @@ jobs:
env:
ALLOW_ANONYMOUS_LOGIN: "yes"
CONFDIR: "/app/samvera/hyrax-webapp/solr/config"
DB_CLEANER_ALLOW_REMOTE_DB_URL: "true"
SE_NODE_SESSION_TIMEOUT: 999999
TB_RSPEC_FORMATTER: progress
TB_RSPEC_OPTIONS: --format RspecJunitFormatter --out rspec.xml
steps:
- name: Set env
run: >-
Expand Down Expand Up @@ -191,76 +196,6 @@ jobs:
fail_on_failure: true
require_passed_tests: true
detailed_summary: true
# NOTE Bootboot enablement
# build-rails-7-0:
# runs-on: ubuntu-latest
# steps:
# - name: Set env
# run: >-
# echo "TAG=${HEAD_TAG::8}" >> ${GITHUB_ENV};
# echo ${HEAD_TAG::8}
# env:
# HEAD_TAG: ${{ github.event.pull_request.head.sha || github.sha }}
# SE_NODE_SESSION_TIMEOUT: 999999
# DEPENDENCIES_NEXT: 1
# BUNDLE_GEMFILE: Gemfile_next
# BUNDLER_VERSION: 2.0.1
# shell: bash
# - name: Downcase repo
# run: echo "REPO_LOWER=${REPO,,}" >> $GITHUB_ENV
# env:
# REPO: '${{ github.repository }}'
# - name: Checkout code
# uses: actions/checkout@v3
# - name: Set up QEMU
# uses: docker/setup-qemu-action@v2
# - name: Set up Docker Buildx
# uses: docker/setup-buildx-action@v2
# - name: Github Container Login
# uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9
# with:
# registry: ${{ env.REGISTRY }}
# username: ${{ github.actor }}
# password: ${{ secrets.GITHUB_TOKEN }}
# - name: Pull from cache to speed up build
# run: >-
# touch .env.development;
# TAG=latest docker compose pull web || true
# - name: Setup tmate session
# uses: mxschmitt/action-tmate@v3
# if: ${{ github.event_name == 'workflow_dispatch' && inputs.debug_enabled }}
# with:
# limit-access-to-actor: true
# - name: Build and push
# uses: docker/build-push-action@v3
# with:
# context: .
# # platforms: linux/amd64,linux/arm64
# platforms: linux/amd64
# target: ams-base
# build-args: |
# SETTINGS__BULKRAX__ENABLED=true
# EXTRA_APK_PACKAGES=less vim bash openjdk11-jre ffmpeg rsync yarn
# cache-from: |
# ${{ env.REGISTRY }}/${{ env.REPO_LOWER }}:${TAG}
# push: true
# tags: |
# ${{ env.REGISTRY }}/${{ env.REPO_LOWER }}:${{ env.TAG }}
# - name: Build and push worker
# uses: docker/build-push-action@v3
# with:
# context: .
# platforms: linux/amd64
# # platforms: linux/amd64,linux/arm64
# target: ams-worker
# build-args: |
# SETTINGS__BULKRAX__ENABLED=true
# EXTRA_APK_PACKAGES=less vim bash openjdk11-jre ffmpeg rsync yarn
# cache-from: |
# ${{ env.REGISTRY }}/${{ env.REPO_LOWER }}:${TAG}
# push: true
# tags: |
# ${{ env.REGISTRY }}/${{ env.REPO_LOWER }}/worker:${{ env.TAG }}

# lint:
# needs: build
Expand Down Expand Up @@ -293,86 +228,3 @@ jobs:
# if: always() # always run even if the previous step fails
# with:
# report_paths: 'rubocop*.xml'

# NOTE Bootboot enablement
# test-rails-7-0:
# needs: build-rails-7-0
# runs-on: ubuntu-latest
# strategy:
# fail-fast: false
# matrix:
# # Set N number of parallel jobs you want to run tests on.
# # Use higher number if you have slow tests to split them on more parallel jobs.
# # Remember to update ci_node_index below to 0..N-1
# ci_node_total: [3]
# # set N-1 indexes for parallel jobs
# # When you run 2 parallel jobs then first job will have index 0, the second job will have index 1 etc
# ci_node_index: [0, 1, 2]
# env:
# ALLOW_ANONYMOUS_LOGIN: "yes"
# BUNDLE_GEMFILE: Gemfile_next
# BUNDLER_VERSION: 2.0.1
# CONFDIR: "/app/samvera/hyrax-webapp/solr/config"
# DB_CLEANER_ALLOW_REMOTE_DB_URL: "true"
# DEPENDENCIES_NEXT: 1
# SE_NODE_SESSION_TIMEOUT: 999999
# TB_RSPEC_FORMATTER: progress
# TB_RSPEC_OPTIONS: --format RspecJunitFormatter --out rspec.xml
# steps:
# - name: Set env
# run: >-
# echo "TAG=${HEAD_TAG::8}" >> ${GITHUB_ENV};
# echo ${HEAD_TAG::8}
# env:
# HEAD_TAG: ${{ github.event.pull_request.head.sha || github.sha }}
# shell: bash
# - name: Checkout code
# uses: actions/checkout@v3
# - name: Github Container Login
# uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9
# with:
# registry: ${{ env.REGISTRY }}
# username: ${{ github.actor }}
# password: ${{ secrets.GITHUB_TOKEN }}
# - name: Pull from cache to speed up build
# run: >-
# touch .env.development;
# docker compose pull web;
# docker compose pull worker
# - name: Setup tmate session
# uses: mxschmitt/action-tmate@v3
# if: ${{ github.event_name == 'workflow_dispatch' && inputs.debug_enabled }}
# with:
# limit-access-to-actor: true
# - name: Start containers
# run: docker compose up -d web
# - name: Setup solr
# run: >-
# docker compose exec -T web bash -c
# "solrcloud-upload-configset.sh /app/samvera/hyrax-webapp/solr/config &&
# SOLR_COLLECTION_NAME=hydra-test solrcloud-assign-configset.sh &&
# solrcloud-assign-configset.sh"
# - name: Setup db
# run: >-
# docker compose exec -T web bash -c
# "DEPENDENCIES_NEXT=1 RAILS_ENV=test bundle exec rake db:schema:load db:migrate db:seed"
# - name: Run Specs
# id: run-specs
# env:
# # Specifies how many jobs you would like to run in parallel,
# # used for partitioning
# CI_NODE_TOTAL: ${{ matrix.ci_node_total }}
# # Use the index from matrix as an environment variable
# CI_NODE_INDEX: ${{ matrix.ci_node_index }}
# continue-on-error: true
# run: >-
# docker compose exec -T web bash -c
# "DEPENDENCIES_NEXT=1 gem install semaphore_test_boosters &&
# DEPENDENCIES_NEXT=1 rspec_booster --job $CI_NODE_INDEX/$CI_NODE_TOTAL"
# - name: Fail job if spec failure
# run: if [[ ${{ steps.run-specs.outcome }} == "failure" ]]; then exit 1; else exit 0; fi
# - name: Publish Test Report
# uses: mikepenz/action-junit-report@v3
# if: always() # always run even if the previous step fails
# with:
# report_paths: 'rspec*.xml'
2 changes: 1 addition & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ GIT

GIT
remote: https://github.com/samvera/hyrax.git
revision: 43165fe0e360a60bf5470db1d3d55538217fcc7b
revision: a904e5a07040c148e4d6c3a9288d048efc8e42b9
branch: double_combo
specs:
hyrax (5.0.0.rc1)
Expand Down
1 change: 1 addition & 0 deletions app/matchers/concerns/has_ams_matchers.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ def field_supported?(field)
return true if field == "title"
return true if field == "description"
return true if field == "subject"
return true if field == "contributors"

property_defined = factory_class.singleton_methods.include?(:properties) && factory_class.properties[field].present?

Expand Down
1 change: 1 addition & 0 deletions app/models/asset_resource.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
class AssetResource < Hyrax::Work
include Hyrax::Schema(:basic_metadata)
include Hyrax::Schema(:asset_resource)
include Hyrax::ArResource
include AMS::WorkBehavior
include AMS::CreateMemberMethods

Expand Down
1 change: 1 addition & 0 deletions app/models/contribution_resource.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
class ContributionResource < Hyrax::Work
include Hyrax::Schema(:basic_metadata)
include Hyrax::Schema(:contribution_resource)
include Hyrax::ArResource
include AMS::WorkBehavior

self.valid_child_concerns = []
Expand Down
1 change: 1 addition & 0 deletions app/models/digital_instantiation_resource.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ class DigitalInstantiationResource < Hyrax::Work

include Hyrax::Schema(:basic_metadata)
include Hyrax::Schema(:digital_instantiation_resource)
include Hyrax::ArResource
include AMS::WorkBehavior
include ::AMS::CreateMemberMethods
extend CarrierWave::Mount
Expand Down
1 change: 1 addition & 0 deletions app/models/essence_track_resource.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
class EssenceTrackResource < Hyrax::Work
include Hyrax::Schema(:basic_metadata)
include Hyrax::Schema(:essence_track_resource)
include Hyrax::ArResource
include AMS::WorkBehavior

self.valid_child_concerns = []
Expand Down
1 change: 1 addition & 0 deletions app/models/physical_instantiation_resource.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
class PhysicalInstantiationResource < Hyrax::Work
include Hyrax::Schema(:basic_metadata)
include Hyrax::Schema(:physical_instantiation_resource)
include Hyrax::ArResource
include AMS::WorkBehavior
include ::AMS::CreateMemberMethods

Expand Down
14 changes: 0 additions & 14 deletions appspec.yml

This file was deleted.

29 changes: 0 additions & 29 deletions bin/deploy/install.sh

This file was deleted.

6 changes: 0 additions & 6 deletions bin/deploy/verify_service.sh

This file was deleted.

21 changes: 0 additions & 21 deletions bin/scripts/ensure_sidekiq_running.rb

This file was deleted.

Loading

0 comments on commit dd521da

Please sign in to comment.