Update-app error
# support
y
when running the following, I get Region is missing
Copy code
npx medplum aws update-app dev 
Error: Region is missing
but I do have region set in my config file ->
Copy code
"region": "us-east-1",
  "name": "dev",
thanks in advance
I was able to get pass this error by doing -> export AWS_REGION=us-east-1
but now getting a new one
Copy code
Stack not found
ok it seems as we deployed a while ago tags where missing so we added them using this command line ->
Copy code
aws cloudformation update-stack --stack-name [STACK_NAME] \
    --use-previous-template  \
    --tags='[{"Key": "medplum:environment","Value": "[STACK_NAME]"}]' \
    --profile [PROFILE] \
    --region  [REGION] \
    --capabilities CAPABILITY_IAM
r
did this end up working with the added tags? We should probably add a "Troubleshooting" section if so
y
Hi, adding the tag manually worked for
npx medplum aws update-server [env]
but not for the
npx medplum aws update-app [env]
r
Hi @ysael , so the tags should have been added when running the cdk deploy step https://www.medplum.com/docs/self-hosting/install-on-aws#cdk-deploy
Would it all be possible to debug with fresh deployment? We may be in an unknown state in AWS, so it can be hard to troubleshoot
y
Hi, I will try
deployment successful, but still seem to have missing tags
When I try
dev
I get
Stack not found
but when I do
MedplumDev
it says
Config not found
I also tryed renaming the confg file to
medplum.MedplumDev.config.json
then I get stack not found
also deployment seems to have deleted the adding of the tags I did via -> https://discord.com/channels/905144809105260605/1130934518132527195/1130953640857845790 as I get stack not found on server update as well ->
one thing I noticed is that the config file example seem to now have those config added ->
Copy code
"loadBalancerLoggingEnabled": true,
  "loadBalancerLoggingBucket": "medplum-logs-us-east-1",
  "loadBalancerLoggingPrefix": "elb-staging",
  "clamscanEnabled": true,
  "clamscanLoggingBucket": "medplum-logs-us-east-1",
  "clamscanLoggingPrefix": "clamscan"
it is not present in ours as I am guessing from older documentation example, could that be related?
r
Ok, if it's ok let's go through step by step. When running
npx medplum aws init
, what did you use as your 'environment name'?
y
that was done few months ago and I do not remember having to give a env name but my stackname is
MedplumDev
r
if it's ok, would you be willing to run though all the steps from scratch with a new cloudformation stack? Just to avoid doing surgery on the old stack. Could we run through the
init
step again, with an env name of
"dev2"
?
I'm worried that there might be some kind of naming conflict between
dev
and
MedplumDev
y
ok I will try
r
Hi @ysael - I just wanted to let you know that we have pushed an update to the
update-app
command, that should help wiht deploying the app: https://github.com/medplum/medplum/pull/2571
y
👀 thanks a lot I will take a look asap
r
hi @ysael - i just wanted to see if you were able to try this aing
hi @ysael - just wanted to bump this
y
hey @rahul1 I did re-try but had the same problem, ended up updating directly in aws, but as soon as I have a bit of time I will try again, thanks a lot for the bump 🙂
170 Views