If you export the variables in the shell you don’t need to set them in the Julia process. Your julia call fails because the command is single-quoted, which prevents shell variable interpolation, and "$USERNAME" does interpolation of the Julia variable USERNAME which is not set.
3 Likes