Facing issue while setting up discourse on my aws ec2 instance ubuntu20, ebs 30gb ram 1gb

As a general rule, if you’re posting a section of the log, you should include 100 more lines from before where you think you should start, because the actual error is almost always earlier than you might think. Please post a full log, or much more than you did.

Posting the output of

free
df -h
uname -a

will also often be useful.