-
Notifications
You must be signed in to change notification settings - Fork 55
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Multi-vo fts cron fixes #226
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I give these suggestions now, as if secrets can be mounted in a VO specific directory as they are with this cron-job, then that means all files within secrets can have an explicit name , and the secret is created as it currently is {secret}-{vo}, but internally they are all file name wise, identical
voms-proxy-init2 -valid 24:00 -cert /tmp/{{ voms }}/long.proxy -key /tmp/{{ voms }}/long.proxy -out /tmp/x509up_{{ voms }} -voms {{ voms }} -rfc -timeout 5 | ||
if [ $RUCIO_FTS_VOMS_{{ vo | upper }} ] | ||
then | ||
voms-proxy-init2 -valid 24:00 -cert /tmp/{{ vo }}/long.proxy -key /tmp/{{ vo }}/long.proxy -out /tmp/x509up_{{ vo }} -rfc -timeout 5 -voms $RUCIO_FTS_VOMS_{{ vo | upper }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
perhaps the outputs here should also be to the VO directory, and then use a generic name for the output, but organised by the directories, rather than prescribing the naming of the files?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree, it makes it a bit easier to understand and more consistent
then | ||
voms-proxy-init2 -valid 24:00 -cert /tmp/{{ vo }}/long.proxy -key /tmp/{{ vo }}/long.proxy -out /tmp/x509up_{{ vo }} -rfc -timeout 5 -voms $RUCIO_FTS_VOMS_{{ vo | upper }} | ||
else | ||
voms-proxy-init2 -valid 24:00 -cert /tmp/{{ vo }}/long.proxy -key /tmp/{{ vo }}/long.proxy -out /tmp/x509up_{{ vo }} -rfc -timeout 5 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same comment as above
|
||
# Delegate the proxy to the requested servers | ||
{% if RUCIO_FTS_SERVERS is defined %} | ||
{% set ftses = RUCIO_FTS_SERVERS.split(',') %} | ||
{% for fts in ftses %} | ||
fts-rest-delegate --hours=24 --force --key=/tmp/x509up_{{ voms }} --cert=/tmp/x509up_{{ voms }} -s {{ fts }} | ||
fts-rest-delegate --hours=24 --force --key=/tmp/x509up_{{ vo }} --cert=/tmp/x509up_{{ vo }} -s {{ fts }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
change if you agree with above comments
{% endfor %} | ||
{% endif %} | ||
|
||
# Create the corresponding kubernetes secrets if asked | ||
{% if RUCIO_FTS_SECRETS is defined %} | ||
{% set secrets = RUCIO_FTS_SECRETS.split(',') %} | ||
{% for secret in secrets %} | ||
kubectl create secret generic {{ secret }}-{{ voms }} --from-file=/tmp/x509up_{{ voms }} --dry-run=client -o yaml | kubectl apply --validate=false -f - | ||
kubectl create secret generic {{ secret }}-{{ vo }} --from-file=/tmp/x509up_{{ vo }} --dry-run=client -o yaml | kubectl apply --validate=false -f - |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
change if you agree with above comments
Changes made to multi-vo script suggested here rucio/helm-charts#126 :