Skip to content
Snippets Groups Projects
Commit 134776d2 authored by Jean-Paul Calderone's avatar Jean-Paul Calderone
Browse files

Try to put the deploy key on tmpfs

parent cc81ee20
No related branches found
No related tags found
3 merge requests!140Merge staging into production,!122Merge develop into staging,!115Continuous deployment for the grid systems
Pipeline #817 passed
...@@ -87,18 +87,20 @@ deploy-to-staging: ...@@ -87,18 +87,20 @@ deploy-to-staging:
- | - |
# The environment variable is configured with GitLab using Terraform so # The environment variable is configured with GitLab using Terraform so
# we can retain some bare minimum level of confidentiality. # we can retain some bare minimum level of confidentiality.
base64 --decode "${PRIVATESTORAGEIO_STAGING_SSH_DEPLOY_KEY}" > "${PWD}"/deploy_key KEY_DIR="$(mktemp -d -p "${XDG_RUNTIME_DIR}-deploy_key")"
KEY_PATH="${KEY_DIR}/deploy_key"
base64 --decode "${PRIVATESTORAGEIO_STAGING_SSH_DEPLOY_KEY}" > "${KEY_PATH}"
# Update the deployment # Update the deployment
- | - |
./ci-tools/deploy-to-staging "${PWD}"/deploy_key ${name} ./ci-tools/deploy-to-staging "${KEY_PATH}" ${name}
# Remove the key from the filesystem to reduce the chance of unintentional # Remove the key from the filesystem to reduce the chance of unintentional
# disclosure. Overall our handling of this key is still not *particulary* # disclosure. Overall our handling of this key is still not *particulary*
# safe or secure but that's why the key is only authorized to perform a # safe or secure but that's why the key is only authorized to perform a
# single very specific operation. # single very specific operation.
- | - |
rm -v "${PWD}"/deploy_key rm -v "${KEY_PATH}"
deploy-to-production: deploy-to-production:
stage: "deploy" stage: "deploy"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment