Archiva Implementation

Follow the steps below for Archiva implementation:

Create storage account generalpurposev2 with private endpoint

For storage account

az storage account create \

-n sasplatformarchvastg01 \

--resource-group rg-smartopsengg-stg-001 \

-l eastus --kind StorageV2 \

--sku Standard_LRS \

--routing-choice MicrosoftRouting \

--min-tls-version TLS1_0 \

--access-tier Hot \

--tags 'instance= platform'\

--allow-blob-public-access true

PE CREATION

az network private-endpoint create \

--connection-name tttt \

-n pe-sasplatformarchvastg01 \

--private-connection-resource-id /subscriptions/cdf5c496-95b3-4219-9117-35d4e0746d13/resourceGroups/rg-smartopsengg-stg-001/providers/Microsoft.Storage/storageAccounts/sasplatformarchvastg01 \

-g rg-smartopsengg-stg-001 \

--subnet /subscriptions/cdf5c496-95b3-4219-9117-35d4e0746d13/resourceGroups/rg-smartopsengg-stg-001/providers/Microsoft.Network/virtualNetworks/vnet-smartops-stg01-eastus-001/subnets/snet-smartops-stg01-platform \

--group-id file \

--tags 'instance=platform'

Create file share clones-archiva1 and clones-archiva2

Picture 1

 

Use this Copy command to copy the files from source location to destination file share we have created above

For clones-archiva1 > use the below az copy command and run it in bastion

Source - sasmartopsenggeastus001

Destination - sasplatformarchvastg01

azcopy copy 'https://sasmartopsenggeastus001.file.core.windows.net/clones-archiva?sv=2019-12-12&ss=bfqt&srt=sco&sp=rwdlacupx&s*^%%%%%%%%T23:39:05Z&st=2021-02-05T15:39:05Z&spr=https&sig=oNjohoo7NlEznYjzEk6zTvCwkkoG%2F03CbrM4sE6BAMw%3D' 'https://sasplatformarchvastg01.file.core.windows.net/clones-archiva1? sv=2020-02-10&ss=bfqt&srt=sco&sp=rwdlacupx&se=2021-04&^%$$$$$$$###-27T15:46:09Z&st=2021-04-23T07:46:09Z&spr=https&sig=pp%2F3CsxD%2B3Fpa0WvLiN1ZjEjUitGyuE%2B8x8yigy4p2Y%3D' –recursive

Red colour- Shared access signature

We need to take SAS form both source and destination.

Source - sasmartopsenggeastus001

GO to the storage and select Shared access signature

Select allowed resource types for service, container, object and click Generate SAS and connection string

Copy the sv token generated there and paste it in the above command.

 

Picture 5

Destination - sasplatformarchvastg01

GO to the storage and select Shared access signature

Select allowed resource types for service, container, object and click Generate SAS and connection string

Copy the sv token generated there and paste it in the above command.

 

Picture 3

 

Same repeat it for clones-archiva2

 

azcopy copy 'https://sasmartopsenggeastus001.file.core.windows.net/clones-archiva?sv=2019-12-12&ss=bfqt&srt=sco&sp=rwdlacupx&se=2022-01-30T23:39:05Z&st=2021-02-05T15:39:05Z&spr=https&sig=oNjohoo7NlEznY#############vCwkkoG%2F03CbrM4sE6BAMw%3D' 'https://sasplatformarchvastg01.file.core.windows.net/clones-archiva2?sv=2020-02-10&ss=bfqt&srt=sco&sp=rwdlacupx&se=2021-04-27T15:46:09Z&st=2021-04-23T07:46:09Z&spr=https&sig=pp%2&^%%##$%^^^^F3CsxD%2B3Fpa0WvLiN1ZjEjUitGyuE%2B8x8yigy4p2Y%3D' –recursive

Create secrets in key vault for storage accountname and key

(smartopsv1-stg01-azurestorageaccountname – provide secret value as the name of the storage account created -eg sasplatformarchvastg01)

(smartopsv1-stg01-azurestorageaccountkey - provide secret value as the access key value from the storage account created)