Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix technical solution 02 #206

Merged
merged 1 commit into from
Apr 1, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
95 changes: 56 additions & 39 deletions documents/solution/ai/aigc-text-generation-3d-model-with-ecs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Description:
zh-cn: AIGC文本生成3D模型。
Mappings:
Images:
'v2.3.0':
v2.3.0:
cn-zhangjiakou: m-8vb16qkofm9zvs2ifq34
cn-shenzhen: m-wz97ya51lhoajugj52fs
cn-qingdao: m-m5eey29yp3ohwkcl08ig
Expand All @@ -19,7 +19,7 @@ Mappings:
Parameters:
ZoneId:
Type: String
AssociationProperty: ALIYUN::ECS::Instance::ZoneId
AssociationProperty: 'ALIYUN::ECS::Instance::ZoneId'
Label:
en: VSwitch Availability Zone
zh-cn: 交换机可用区
Expand All @@ -28,32 +28,42 @@ Parameters:
Label:
en: Instance Type
zh-cn: 实例类型
AssociationProperty: ALIYUN::ECS::Instance::InstanceType
AssociationProperty: 'ALIYUN::ECS::Instance::InstanceType'
AssociationPropertyMetadata:
ZoneId: ${ZoneId}
SpotStrategy: SpotAsPriceGo
AllowedValues:
- ecs.gn7i-c16g1.4xlarge
- ecs.gn7i-c32g1.8xlarge
- ecs.gn7i-c48g1.12xlarge
Description:
en: This solution requires GPU computing type gn7i series servers. If there are no instance specifications that meet the conditions, please change the region.
en: >-
This solution requires GPU computing type gn7i series servers. If there
are no instance specifications that meet the conditions, please change
the region.
zh-cn: 此方案需要 GPU 计算型 gn7i 系列服务器,如果没有满足条件的实例规格,请更换地域。
InstancePassword:
NoEcho: true
Type: String
Description:
en: Server login password, Length 8-30, must contain three(Capital letters, lowercase letters, numbers, ()`~!@#$%^&*_-+=|{}[]:;'<>,.?/ Special symbol in)
zh-cn: 服务器登录密码,长度8-30,必须包含三项(大写字母、小写字母、数字、 ()`~!@#$%^&*_-+=|{}[]:;'<>,.?/ 中的特殊符号)
en: >-
Server login password, Length 8-30, must contain three(Capital letters,
lowercase letters, numbers, ()`~!@#$%^&*_-+=|{}[]:;'<>,.?/ Special
symbol in)
zh-cn: >-
服务器登录密码,长度8-30,必须包含三项(大写字母、小写字母、数字、 ()`~!@#$%^&*_-+=|{}[]:;'<>,.?/
中的特殊符号)
AllowedPattern: '^[a-zA-Z0-9-\(\)\`\~\!\@\#\$\%\^\&\*\_\-\+\=\|\{\}\[\]\:\;\<\>\,\.\?\/]*$'
Label:
en: Instance Password
zh-cn: 实例密码
ConstraintDescription:
en: Length 8-30, must contain three(Capital letters, lowercase letters, numbers, ()`~!@#$%^&*_-+=|{}[]:;'<>,.?/ Special symbol in)
zh-cn: 长度8-30,必须包含三项(大写字母、小写字母、数字、 ()`~!@#$%^&*_-+=|{}[]:;'<>,.?/ 中的特殊符号)
en: >-
Length 8-30, must contain three(Capital letters, lowercase letters,
numbers, ()`~!@#$%^&*_-+=|{}[]:;'<>,.?/ Special symbol in)
zh-cn: '长度8-30,必须包含三项(大写字母、小写字母、数字、 ()`~!@#$%^&*_-+=|{}[]:;''<>,.?/ 中的特殊符号)'
MinLength: 8
MaxLength: 30
AssociationProperty: ALIYUN::ECS::Instance::Password
AssociationProperty: 'ALIYUN::ECS::Instance::Password'
UserName:
Type: String
Label:
Expand All @@ -64,40 +74,45 @@ Parameters:
NoEcho: true
Type: String
Description:
en: Software login password, Length 8-30, must contain three(Capital letters, lowercase letters, numbers, ()`~!@#$%^&*_-+=|{}[]:;'<>,.?/ Special symbol in)
en: >-
Software login password, Length 8-30, must contain three(Capital
letters, lowercase letters, numbers, ()`~!@#$%^&*_-+=|{}[]:;'<>,.?/
Special symbol in)
zh-cn: 软件登录密码
AllowedPattern: '^[a-zA-Z0-9-\(\)\`\~\!\@\#\$\%\^\&\*\_\-\+\=\|\{\}\[\]\:\;\<\>\,\.\?\/]*$'
Label:
en: Software Login Password
zh-cn: 软件登录密码
ConstraintDescription:
en: Length 8-30, must contain three(Capital letters, lowercase letters, numbers, ()`~!@#$%^&*_-+=|{}[]:;'<>,.?/ Special symbol in)
zh-cn: 长度8-30,必须包含三项(大写字母、小写字母、数字、 ()`~!@#$%^&*_-+=|{}[]:;'<>,.?/ 中的特殊符号)
en: >-
Length 8-30, must contain three(Capital letters, lowercase letters,
numbers, ()`~!@#$%^&*_-+=|{}[]:;'<>,.?/ Special symbol in)
zh-cn: '长度8-30,必须包含三项(大写字母、小写字母、数字、 ()`~!@#$%^&*_-+=|{}[]:;''<>,.?/ 中的特殊符号)'
MinLength: 8
MaxLength: 30
AssociationProperty: ALIYUN::ECS::Instance::Password
AssociationProperty: 'ALIYUN::ECS::Instance::Password'
Resources:
EcsVpc:
Type: ALIYUN::ECS::VPC
Type: 'ALIYUN::ECS::VPC'
Properties:
VpcName:
Ref: ALIYUN::StackName
Ref: 'ALIYUN::StackName'
CidrBlock: 192.168.0.0/16
EcsVSwitch:
Type: ALIYUN::ECS::VSwitch
Type: 'ALIYUN::ECS::VSwitch'
Properties:
VSwitchName:
Ref: ALIYUN::StackName
Ref: 'ALIYUN::StackName'
VpcId:
Ref: EcsVpc
ZoneId:
Ref: ZoneId
CidrBlock: 192.168.0.0/24
EcsSecurityGroup:
Type: ALIYUN::ECS::SecurityGroup
Type: 'ALIYUN::ECS::SecurityGroup'
Properties:
SecurityGroupName:
Ref: ALIYUN::StackName
Ref: 'ALIYUN::StackName'
VpcId:
Ref: EcsVpc
SecurityGroupIngress:
Expand All @@ -123,7 +138,7 @@ Resources:
DestCidrIp: 0.0.0.0/0
NicType: intranet
EcsInstanceGroup:
Type: ALIYUN::ECS::InstanceGroup
Type: 'ALIYUN::ECS::InstanceGroup'
Properties:
IoOptimized: optimized
VpcId:
Expand All @@ -138,28 +153,29 @@ Resources:
SystemDiskSize: 500
MaxAmount: 1
ImageId:
Fn::FindInMap:
'Fn::FindInMap':
- Images
- 'v2.3.0'
- Ref: ALIYUN::Region
- v2.3.0
- Ref: 'ALIYUN::Region'
InstanceType:
Ref: EcsInstanceType
Password:
Ref: InstancePassword
AllocatePublicIP: true
InternetMaxBandwidthOut: 100
SpotStrategy: SpotAsPriceGo
InstanceRunCommand:
Type: ALIYUN::ECS::RunCommand
Type: 'ALIYUN::ECS::RunCommand'
Properties:
Sync: true
Type: RunShellScript
InstanceIds:
Fn::GetAtt:
'Fn::GetAtt':
- EcsInstanceGroup
- InstanceIds
Timeout: '300'
CommandContent:
Fn::Sub: |-
'Fn::Sub': |-
#!/bin/bash
htpasswd -bc /etc/nginx/password ${UserName} ${Password}
systemctl restart nginx
Expand All @@ -173,31 +189,32 @@ Outputs:
zh-cn: ECS登陆地址。
en: Ecs login address.
Value:
Fn::Sub:
- https://ecs-workbench.aliyun.com/?from=EcsConsole&instanceType=ecs&regionId=${Region}&instanceId=${InstanceId}
'Fn::Sub':
- >-
https://ecs-workbench.aliyun.com/?from=EcsConsole&instanceType=ecs&regionId=${Region}&instanceId=${InstanceId}
- InstanceId:
Fn::Select:
'Fn::Select':
- 0
- Fn::GetAtt:
- 'Fn::GetAtt':
- EcsInstanceGroup
- InstanceIds
Region:
Ref: ALIYUN::Region
Ref: 'ALIYUN::Region'
Endpoint:
Description:
zh-cn: WebUI地址。
en: The Addresses of WebUI.
Value:
Fn::Sub:
- http://${ServerAddress}:5000
'Fn::Sub':
- 'http://${ServerAddress}:5000'
- ServerAddress:
Fn::Select:
'Fn::Select':
- 0
- Fn::GetAtt:
- EcsInstanceGroup
- PublicIps
- 'Fn::GetAtt':
- EcsInstanceGroup
- PublicIps
Metadata:
ALIYUN::ROS::Interface:
'ALIYUN::ROS::Interface':
TemplateTags:
- 'acs:technical-solution:ai:文本生成3D模型-tech_solu_02'
ParameterGroups:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ Parameters:
zh-cn: 加速域名
en: Accelerated domain name
Description:
zh-cn: 加速域名是指接入CDN,用于加速源站的域名。请填写您账号下的域名。
zh-cn: 加速域名是指接入CDN,用于加速源站的域名。请填写您账号下的域名。仅支持二级域名,例如 prefix.example.com。
en: Accelerated domain name refers to the domain name of the access CDN used to accelerate the source site. Please fill in the domain name under your account.
BucketName:
Type: String
Expand Down
Loading