Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Updates embargo scripts. #1164

Merged
merged 2 commits into from
May 21, 2024
Merged

Updates embargo scripts. #1164

merged 2 commits into from
May 21, 2024

Conversation

scherztc
Copy link
Contributor

@scherztc scherztc commented May 8, 2024

Fixes #1165

The embargo scripts are not being used in cron since the date -v function is crashing. We need to clean up these scripts and then set them in crontab.

We have also separated the notification and releasing into their own scripts instead of doing it crontab.

Copy link
Member

@hortongn hortongn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@scherztc Hard coding RAILS_ENV=production means these scripts won't work in development. Is that ok? Thoughts?

@scherztc
Copy link
Contributor Author

Yeah. I had concerns.
I didn't see environment in the .env files.
So, I am working to find a way to pull that information from the environment.
Any ideas?

@hortongn
Copy link
Member

Perhaps the same way we handle script/restart_sidekiq.sh. We call that script with a parameter to specify the right environment. Like script/restart_sidekiq.sh development or script/restart_sidekiq.sh production

Look at the script/restart_sidekiq.sh source for how we're using ENVIRONMENT to grab and use the parameter.

Copy link
Member

@hortongn hortongn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@scherztc You can remove the THREADS=$2 and RVM=$3 since we're not using those variables. Also remove the banner lines. We want cron tasks to run without output unless there's an error. Cron sends emails whenever there's output from a cron job.

@scherztc scherztc force-pushed the fix/embargo_script branch from 36c2427 to b6b1d83 Compare May 20, 2024 18:41
@scherztc
Copy link
Contributor Author

I tested this on DEV and it worked successfully with the application in INLINE mode verse SIDEKIQ mode.
I repeat these scripts works on DEV

@hortongn hortongn merged commit edc4342 into develop May 21, 2024
1 of 2 checks passed
@hortongn hortongn deleted the fix/embargo_script branch May 21, 2024 20:08
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Date utility is broken outside of Mac environments
2 participants