I have done some research into this and did come across the following blog post which goes through the steps to set this up. The steps may be slightly different depending on Identity Provider you are using with AWS SSO(When testing this I was using the Default SSO Directory, the blog post shows the same set up with OKTA as an Identity Provider).
The one thing I would like to point out is the solution in the blog does not add the users to the
/etc/passwd file, it instead creates a user on the instance with the same username as that attribute you have mapped to SSMSessionRunAs in AWS SSO. When the user logs into the instance via instance connect, they will log in as the user that you created on the ec2 instance.
I did manage to get this working in my test environment so if you have any questions please feel free to let me know.
 Configure AWS SSO ABAC for EC2 instances and Systems Manager Session Manager - https://aws.amazon.com/blogs/security/configure-aws-sso-abac-for-ec2-instances-and-systems-manager-session-manager/
AWS SSO Access for Linux?asked 8 months ago
Using Terraform with AWS SSO accountsasked 2 months ago
boto3 "logging" into the AWS SSOAccepted Answerasked 8 months ago
AWS SSO IDp For OpenSearchasked 2 months ago
AWS SSO EC2 RDPasked 5 months ago
AWS SSO ForbiddenExceptionasked 5 months ago
AWS SSO on Amazon Linuxasked 8 months ago
AWS SSO - what OU/account to use?asked 5 months ago
send AWS SSO username as a attribute in SAML assertionasked 2 years ago
AWS SSO with Amazon Managed Grafana not working (redirection to NULL)asked 9 months ago