2 months ago
In github action we create new PR environments
This call is slow, takes between 2 and 3 minutes. Is that expected?
railway environment new "$preview_env" --duplicate "$source_env"Full action context:
set -euo pipefail
source_env="${RAILWAY_SOURCE_ENVIRONMENT:-staging}"
preview_env="pr-${PR_NUMBER}"
if railway environment "$preview_env" >/dev/null 2>&1; then
echo "Using existing Railway environment: ${preview_env}"
exit 0
fi
railway environment new "$preview_env" --duplicate "$source_env"
railway environment "$preview_env" >/dev/null
shell: /usr/bin/bash -e {0}
env:
PNPM_HOME: /home/runner/setup-pnpm/node_modules/.bin
PR_NUMBER: 1152
RAILWAY_SOURCE_ENVIRONMENT:
RAILWAY_API_TOKEN: ***
> Environment name pr-1152
> Duplicate from staging
2 Replies
2 months ago
Hey there! We've found the following might help you get unblocked faster:
If you find the answer from one of these, please let us know by solving the thread!
2 months ago
Hello,
A community member is actively working on massive improvements here - https://github.com/railwayapp/cli/pull/702
Not just to allow adding a source, but a near entire rewrite to the command, so please let me know if things improve after that is released!
Best,
Brody
Status changed to Awaiting User Response Railway • 2 months ago
2 months ago
This thread has been marked as solved automatically due to a lack of recent activity. Please re-open this thread or create a new one if you require further assistance. Thank you!
Status changed to Solved Railway • about 2 months ago