Good day
I want to pass the value of $mm to this azcopy. However, since azcopy parameters are in double quotes, it does not want to process correctly.
$mm=04 ; start=`echo "START DATE: $(date)"` ; azcopy cp "https://reco.blob.core.windows.net/raw-voi-2022/2022-$mm/*?sv=2020-0RgUNH8A%3D" "https://storage.blob.core.windows.net/bin-voi-2022/2022-$mm?sv=2021-0HGICxvaLULI%3D"
Results:
Job 24fa36ea-8bda-cc4f-632a-07db4d922036 has started
Log file is located at: /log/azcopy/24fa36ea-8bda-cc4f-632a-07db4d922036.log
100.0 %, 0 Done, 0 Failed, 0 Pending, 0 Skipped, 0 Total,
Job 24fa36ea-8bda-cc4f-632a-07db4d922036 summary Elapsed Time (Minutes): 0.0333
Number of File Transfers: 0
Number of Folder Property Transfers: 0
Number of Symlink Transfers: 0
Total Number of Transfers: 0
Number of File Transfers Completed: 0
Number of Folder Transfers Completed: 0
Number of File Transfers Failed: 0
Number of Folder Transfers Failed: 0
Number of File Transfers Skipped: 0
Number of Folder Transfers Skipped: 0
TotalBytesTransferred: 0
Final Job Status: Completed
Thank you.
2
Answers
When you are in a Linux os, don't use $ to declare a variable.
I have summarized our discussion and posting the above comment as an answer.
Since you are running the above cmdlet in Linux, you need to initialize the variable with as
mm=04
instead of using$mm=04