ΠΡΠ΅ΠΌ ΠΏΡΠΈΠ²Π΅Ρ, ΠΌΠ΅Π½Ρ Π·ΠΎΠ²ΡΡ ΠΠ²Π°Π½ ΠΈ Ρ Π°Π»ΠΊΠΎΠ³ΠΎΠ»ΠΈΠΊ ΡΠΈΡΡΠ΅ΠΌΠ½ΡΠΉ Π°Π΄ΠΌΠΈΠ½ΠΈΡΡΡΠ°ΡΠΎΡ (OPS).
Π― Π±Ρ Ρ
ΠΎΡΠ΅Π» ΡΠ°ΡΡΠΊΠ°Π·Π°ΡΡ ΠΊΠ°ΠΊ ΡΠ°Π·Π²ΠΎΡΠ°ΡΠΈΠ²Π°Ρ Π²ΠΈΡΡΡΠ°Π»ΡΠ½ΡΠ΅ ΠΌΠ°ΡΠΈΠ½Ρ Π½Π° ESXi Π±Π΅Π· vCenter Ρ ΠΏΠΎΠΌΠΎΡΡΡ Terraform.
ΠΠΎΠ²ΠΎΠ»ΡΠ½ΠΎ ΡΠ°ΡΡΠΎ ΠΏΡΠΈΡ
ΠΎΠ΄ΠΈΡΡΡ ΡΠ°Π·Π²ΠΎΡΠ°ΡΠΈΠ²Π°ΡΡ/ΠΏΠ΅ΡΠ΅ΡΠΎΠ·Π΄Π°Π²Π°ΡΡ Π²ΠΈΡΡΡΠ°Π»ΠΊΠΈ, ΡΡΠΎ Π±Ρ ΠΏΡΠΎΡΠ΅ΡΡΠΈΡΠΎΠ²Π°ΡΡ ΡΠΎ ΠΈΠ»ΠΈ ΠΈΠ½ΠΎΠ΅ ΠΏΡΠΈΠ»ΠΎΠΆΠ΅Π½ΠΈΠ΅. Π ΡΠΈΠ»Ρ Π»Π΅Π½ΠΈ Ρ ΠΏΠΎΠ΄ΡΠΌΠ°Π» ΠΎΠ± Π°Π²ΡΠΎΠΌΠ°ΡΠΈΠ·Π°ΡΠΈΠΈ ΠΏΡΠΎΡΠ΅ΡΡΠ°. ΠΠΎΠΈ ΠΏΠΎΠΈΡΠΊΠΈ ΠΏΡΠΈΠ²Π΅Π»ΠΈ ΠΌΠ΅Π½Ρ ΠΊ Π·Π°ΠΌΠ΅ΡΠ°ΡΠ΅Π»ΡΠ½ΠΎΠΌΡ ΠΏΡΠΎΠ΄ΡΠΊΡΡ ΠΊΠΎΠΌΠΏΠ°Π½ΠΈΠΈ
ΠΡΠΌΠ°Ρ ΠΌΠ½ΠΎΠ³ΠΈΠ΅ Π·Π½Π°ΡΡ ΡΡΠΎ ΡΠ°ΠΊΠΎΠ΅ Terraform, Π° ΠΊΡΠΎ Π½Π΅ Π·Π½Π°Π΅Ρ, ΡΡΠΎ ΠΏΡΠΈΠ»ΠΎΠΆΠ΅Π½ΠΈΠ΅ Π΄Π»Ρ ΡΠΏΡΠ°Π²Π»Π΅Π½ΠΈΡ Π»ΡΠ±ΡΠΌ ΠΎΠ±Π»Π°ΠΊΠΎΠΌ, ΠΈΠ½ΡΡΠ°ΡΡΡΡΠΊΡΡΡΠΎΠΉ ΠΈΠ»ΠΈ ΡΠ»ΡΠΆΠ±ΠΎΠΉ ΠΈΡΠΏΠΎΠ»ΡΠ·ΡΡ ΠΊΠΎΠ½ΡΠ΅ΠΏΡΠΈΡ IasC (ΠΠ½ΡΡΠ°ΡΡΡΡΠΊΡΡΡΠ° ΠΊΠ°ΠΊ ΠΊΠΎΠ΄).
Π ΠΊΠ°ΡΠ΅ΡΡΠ²Π΅ ΡΡΠ΅Π΄Ρ Π²ΠΈΡΡΡΠ°Π»ΠΈΠ·Π°ΡΠΈΠΈ Ρ ΠΈΡΠΏΠΎΠ»ΡΠ·ΡΡ ESXi. ΠΠΎΠ²ΠΎΠ»ΡΠ½ΠΎ ΠΏΡΠΎΡΡΠ°Ρ, ΡΠ΄ΠΎΠ±Π½Π°Ρ ΠΈ Π½Π°Π΄ΡΠΆΠ½Π°Ρ.
ΠΡΠ΅Π΄Π²ΠΈΠΆΡ Π²ΠΎΠΏΡΠΎΡ.
ΠΠ°ΡΠ΅ΠΌ terraform Π΅ΡΠ»ΠΈ ΠΌΠΎΠΆΠ½ΠΎ ΠΈΡΠΏΠΎΠ»ΡΠ·ΠΎΠ²Π°ΡΡ vCenter Server?
ΠΠΎΠΆΠ½ΠΎ ΠΊΠΎΠ½Π΅ΡΠ½ΠΎ, Π½ΠΎ. ΠΠΎ-ΠΏΠ΅ΡΠ²ΡΡ , ΡΡΠΎ Π΄ΠΎΠΏΠΎΠ»Π½ΠΈΡΠ΅Π»ΡΠ½Π°Ρ Π»ΠΈΡΠ΅Π½Π·ΠΈΡ, Π²ΠΎ-Π²ΡΠΎΡΡΡ , Π΄Π°Π½Π½ΡΠΉ ΠΏΡΠΎΠ΄ΡΠΊΡ ΠΎΡΠ΅Π½Ρ ΡΠ΅ΡΡΡΡΠΎΠ΅ΠΌΠΊΠΈΠΉ ΠΈ ΠΏΡΠΎΡΡΠΎ Π½Π΅ ΠΏΠΎΠΌΠ΅ΡΡΠΈΡΡΡ Π½Π° ΠΌΠΎΡΠΌ Π΄ΠΎΠΌΠ°ΡΠ½Π΅ΠΌ ΡΠ΅ΡΠ²Π΅ΡΠ΅, ΠΈ Π²-ΡΡΠ΅ΡΡΠΈΡ Π²ΠΎΠ·ΠΌΠΎΠΆΠ½ΠΎΡΡΡ ΠΏΡΠΎΠΊΠ°ΡΠ°ΡΡ ΡΠΊΠΈΠ»Π»Ρ.
Π ΠΊΠ°ΡΠ΅ΡΡΠ²Π΅ ΡΠ΅ΡΠ²Π΅ΡΠ° Π²ΡΡΡΡΠΏΠ°Π΅Ρ ΠΏΠ»Π°ΡΡΠΎΡΠΌΠ° Intel NUC:
CPU: 2 CPUs x Intel(R) Core(TM) i3-4010U CPU @ 1.70GHz
RAM: 8Gb
HDD: 500Gb
ESXi version: ESXi-6.5.0-4564106-standard (VMware, Inc.)
Π ΡΠ°ΠΊ, ΠΎΠ±ΠΎ Π²ΡΡΠΌ ΠΏΠΎ ΠΏΠΎΡΡΠ΄ΠΊΡ.
ΠΠΎΠΊΠ° Π΄Π°Π²Π°ΠΉΡΠ΅ Π½Π°ΡΡΡΠΎΠΈΠΌ esxi, Π° ΠΈΠΌΠ΅Π½Π½ΠΎ ΠΎΡΠΊΡΠΎΠ΅ΠΌ VNC ΠΏΠΎΡΡ Π² Π½Π°ΡΡΡΠΎΠΉΠΊΠ°Ρ ΡΠ°ΠΉΡΠ²ΠΎΠ»Π°.
ΠΠΎ ΡΠΌΠΎΠ»ΡΠ°Π½ΠΈΡ, ΡΠ°ΠΉΠ» Π·Π°ΡΠΈΡΡΠ½ ΠΎΡ Π·Π°ΠΏΠΈΡΠΈ. ΠΡΠΎΠ²ΠΎΠ΄ΠΈΠΌ ΡΠ»Π΅Π΄ΡΡΡΠΈΠ΅ ΠΌΠ°Π½ΠΈΠΏΡΠ»ΡΡΠΈΠΈ:
chmod 644 /etc/vmware/firewall/service.xml
chmod +t /etc/vmware/firewall/service.xml
vi /etc/vmware/firewall/service.xml
Π΄ΠΎΠΏΠΈΡΡΠ²Π°Π΅ΠΌ Π² ΠΊΠΎΠ½Π΅Ρ ΡΠ°ΠΉΠ»Π° ΡΠ»Π΅Π΄ΡΡΡΠΈΠΉ Π±Π»ΠΎΠΊ:
<service id="1000">
<id>packer-vnc</id>
<rule id="0000">
<direction>inbound</direction>
<protocol>tcp</protocol>
<porttype>dst</porttype>
<port>
<begin>5900</begin>
<end>6000</end>
</port>
</rule>
<enabled>true</enabled>
<required>true</required>
</service>
ΠΡΡ ΠΎΠ΄ΠΈΠΌ, ΡΠΎΡ ΡΠ°Π½ΡΠ΅ΠΌ. ΠΠ΅Π½ΡΠ΅ΠΌ ΠΏΡΠ°Π²Π° ΠΎΠ±ΡΠ°ΡΠ½ΠΎ ΠΈ ΠΏΠ΅ΡΠ΅Π·Π°Π³ΡΡΠΆΠ°Π΅ΠΌ ΡΠ΅ΡΠ²ΠΈΡ:
chmod 444 /etc/vmware/firewall/service.xml
esxcli network firewall refresh
ΠΠΊΡΡΠ°Π»ΡΠ½ΠΎ Π΄ΠΎ ΠΏΠ΅ΡΠ΅Π·Π°Π³ΡΡΠ·ΠΊΠΈ Ρ ΠΎΡΡΠ°. ΠΠΎΡΠ»Π΅ ΠΆΠ΅, Π΄Π°Π½Π½ΡΡ ΠΌΠ°Π½ΠΈΠΏΡΠ»ΡΡΠΈΡ ΠΏΡΠΈΠ΄ΡΡΡΡ ΠΏΠΎΠ²ΡΠΎΡΠΈΡΡ.
ΠΠ°Π»ΡΡΠ΅ Π²ΡΡ ΡΠ°Π±ΠΎΡΡ Π±ΡΠ΄Ρ ΠΏΡΠΎΠ²ΠΎΠ΄ΠΈΡΡ Π² Π²ΠΈΡΡΡΠ°Π»ΡΠ½ΠΎΠΉ ΠΌΠ°ΡΠΈΠ½Π΅ Π½Π° ΡΡΠΎΠΌ ΠΆΠ΅ ΡΠ΅ΡΠ²Π΅ΡΠ΅.
Π₯Π°ΡΠ°ΠΊΡΠ΅ΡΠΈΡΡΠΈΠΊΠΈ:
OS: Centos 7 x86_64 minimal
RAM: 1GB
HDD: 20GB
Selinux: disable
firewalld: disable
ΠΠ°Π»Π΅Π΅ Π½Π°ΠΌ ΠΏΠΎΡΡΠ΅Π±ΡΠ΅ΡΡΡ
ΠΡΠΆΠ΅Π½ ΠΎΠ½, Π΄Π»Ρ Π°Π²ΡΠΎΠΌΠ°ΡΠΈΡΠ΅ΡΠΊΠΎΠΉ ΡΠ±ΠΎΡΠΊΠΈ Β«Π·ΠΎΠ»ΠΎΡΠΎΠ³ΠΎΒ» ΠΎΠ±ΡΠ°Π·Π°. ΠΠΎΡΠΎΡΡΠΉ ΠΌΡ Π±ΡΠ΄Π΅ΠΌ ΠΈΡΠΏΠΎΠ»ΡΠ·ΠΎΠ²Π°ΡΡ Π² Π±ΡΠ΄ΡΡΠ΅ΠΌ.
yum install unzip git -y
curl -O https://releases.hashicorp.com/packer/1.5.5/packer_1.5.5_linux_amd64.zip
unzip packer_1.5.5_linux_amd64.zip -d /usr/bin && rm -rf packer_1.5.5_linux_amd64.zip
packer version
Packer v1.5.5
ΠΠ° ΡΠ°Π³Π΅ packer version ΠΌΠΎΠΆΠ΅Ρ Π²ΠΎΠ·Π½ΠΈΠΊΠ½ΡΡΡ ΠΎΡΠΈΠ±ΠΊΠ°, ΡΠ°ΠΊ ΠΊΠ°ΠΊ Π² RedHat-based ΠΌΠΎΠΆΠ΅Ρ Π½Π°Ρ ΠΎΠ΄ΠΈΡΡΡΡ ΠΏΠ°ΠΊΠ΅Ρ Ρ ΡΠ°ΠΊΠΈΠΌ ΠΆΠ΅ Π½Π°Π·Π²Π°Π½ΠΈΠ΅ΠΌ.
which -a packer
/usr/sbin/packer
ΠΠ»Ρ ΡΠ΅ΡΠ΅Π½ΠΈΡ ΠΌΠΎΠΆΠ½ΠΎ ΡΠΎΠ·Π΄Π°ΡΡ ΡΠΈΠΌΠ»ΠΈΠ½ΠΊ, Π»ΠΈΠ±ΠΎ ΠΈΡΠΏΠΎΠ»ΡΠ·ΠΎΠ²Π°ΡΡ Π°Π±ΡΠΎΠ»ΡΡΠ½ΡΠΉ ΠΏΡΡΡ /usr/bin/packer.
Π’Π΅ΠΏΠ΅ΡΡ Π½Π°ΠΌ ΠΏΠΎΡΡΠ΅Π±ΡΠ΅ΡΡΡ ovftool
chmod +x VMware-ovftool-4.4.0-15722219-lin.x86_64.bundle
./VMware-ovftool-4.4.0-15722219-lin.x86_64.bundle
Extracting VMware Installer...done.
You must accept the VMware OVF Tool component for Linux End User
License Agreement to continue. Press Enter to proceed.
VMWARE END USER LICENSE AGREEMENT
Do you agree? [yes/no]:yes
The product is ready to be installed. Press Enter to begin
installation or Ctrl-C to cancel.
Installing VMware OVF Tool component for Linux 4.4.0
Configuring...
[######################################################################] 100%
Installation was successful.
ΠΠ²ΠΈΠΆΠ΅ΠΌΡΡ Π΄Π°Π»ΡΡΠ΅.
ΠΠ° Π³ΠΈΡΠ΅ Ρ ΠΏΠΎΠ΄Π³ΠΎΡΠΎΠ²ΠΈΠ» Π²ΡΡ Π½Π΅ΠΎΠ±Ρ ΠΎΠ΄ΠΈΠΌΠΎΠ΅.
git clone https://github.com/letnab/create-and-deploy-esxi.git && cd create-and-deploy-esxi
Π ΠΏΠ°ΠΏΠΊΡ iso Π½ΡΠΆΠ½ΠΎ ΠΏΠΎΠ»ΠΎΠΆΠΈΡΡ Π΄ΠΈΡΡΡΠΈΠ±ΡΡΠΈΠ² ΠΎΠΏΠ΅ΡΠ°ΡΠΈΠΎΠ½Π½ΠΎΠΉ ΡΠΈΡΡΠ΅ΠΌΡ. Π ΠΌΠΎΡΠΌ ΡΠ»ΡΡΠ°Π΅ ΡΡΠΎ centos 7.
Π’Π°ΠΊ ΠΆΠ΅ Π½Π΅ΠΎΠ±Ρ ΠΎΠ΄ΠΈΠΌΠΎ ΠΎΡΡΠ΅Π΄Π°ΠΊΡΠΈΡΠΎΠ²Π°ΡΡ ΡΠ°ΠΉΠ» centos-7-base.json:
variables: ΡΠΊΠ°Π·Π°ΡΡ ΡΠ²ΠΎΠΈ Π΄Π°Π½Π½ΡΠ΅ Π΄Π»Ρ ΠΏΠΎΠ΄ΠΊΠ»ΡΡΠ΅Π½ΠΈΡ
iso_urls: ΡΠΊΠ°Π·Π°ΡΡ Π°ΠΊΡΡΠ°Π»ΡΠ½ΡΠΉ
iso_checksum: ΡΠ΅ΠΊΡΡΠΌΠΌΠ° Π²Π°ΡΠ΅Π³ΠΎ ΠΎΠ±ΡΠ°Π·Π°
ΠΠΎΡΠ»Π΅ Π²ΡΠ΅Ρ ΠΈΠ·ΠΌΠ΅Π½Π΅Π½ΠΈΠΉ Π·Π°ΠΏΡΡΠΊΠ°Π΅ΠΌ ΡΠ±ΠΎΡΠΊΡ:
/usr/bin/packer build centos-7-base.json
ΠΡΠ»ΠΈ Π²ΡΡ Π½Π°ΡΡΡΠΎΠ΅Π½ΠΎ ΠΈ ΡΠΊΠ°Π·Π°Π½ΠΎ Π²Π΅ΡΠ½ΠΎ, ΡΠΎ Π²Ρ ΡΠ²ΠΈΠ΄ΠΈΡΠ΅ ΠΊΠ°ΡΡΠΈΠ½Ρ Π°Π²ΡΠΎΠΌΠ°ΡΠΈΡΠ΅ΡΠΊΠΎΠΉ ΠΈΠ½ΡΡΠ°Π»Π»ΡΡΠΈΠΈ ΠΎΠΏΠ΅ΡΠ°ΡΠΈΠΎΠ½Π½ΠΎΠΉ ΡΠΈΡΡΠ΅ΠΌΡ. ΠΠ°Π½Π½ΡΠΉ ΠΏΡΠΎΡΠ΅ΡΡ Ρ ΠΌΠ΅Π½Ρ Π·Π°Π½ΠΈΠΌΠ°Π΅Ρ 7-8 ΠΌΠΈΠ½ΡΡ.
ΠΠΎΡΠ»Π΅ ΡΡΠΏΠ΅ΡΠ½ΠΎΠ³ΠΎ Π·Π°Π²Π΅ΡΡΠ΅Π½ΠΈΡ Π² ΠΏΠ°ΠΏΠΊΠ΅ output-packer-centos7-x86_64 Π±ΡΠ΄Π΅Ρ Π½Π°Ρ ΠΎΠ΄ΠΈΡΡΡ ova ΡΠ°ΠΉΠ».
Π£ΡΡΠ°Π½Π°Π²Π»ΠΈΠ²Π°Π΅ΠΌ Terraform:
curl -O https://releases.hashicorp.com/terraform/0.12.24/terraform_0.12.24_linux_amd64.zip
unzip terraform_0.12.24_linux_amd64.zip -d /usr/bin/ && rm -rf terraform_0.12.24_linux_amd64.zip
terraform version
Terraform v0.12.24
Π’Π°ΠΊ ΠΊΠ°ΠΊ Ρ Terraform Π½Π΅Ρ ΠΏΡΠΎΠ²Π°ΠΉΠ΄Π΅ΡΠ° ΠΏΠΎΠ΄ ESXi, Π½ΡΠΆΠ½ΠΎ Π΅Π³ΠΎ ΡΠΎΠ±ΡΠ°ΡΡ.
Π‘ΡΠ°Π²ΠΈΠΌ go:
cd /tmp
curl -O https://dl.google.com/go/go1.14.2.linux-amd64.tar.gz
tar -C /usr/local -xzf go1.14.2.linux-amd64.tar.gz && rm -rf go1.14.2.linux-amd64.tar.gz
export PATH=$PATH:/usr/local/go/bin
go version
go version go1.14.2 linux/amd64
ΠΠ°Π»Π΅Π΅ ΡΠΎΠ±ΠΈΡΠ°Π΅ΠΌ ΠΏΡΠΎΠ²Π°ΠΉΠ΄Π΅Ρ:
go get -u -v golang.org/x/crypto/ssh
go get -u -v github.com/hashicorp/terraform
go get -u -v github.com/josenk/terraform-provider-esxi
export GOPATH="$HOME/go"
cd $GOPATH/src/github.com/josenk/terraform-provider-esxi
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -a -ldflags '-w -extldflags "-static"' -o terraform-provider-esxi_`cat version`
cp terraform-provider-esxi_`cat version` /usr/bin
ΠΡ Π½Π° ΡΠΈΠ½ΠΈΡΠ½ΠΎΠΉ ΠΏΡΡΠΌΠΎΠΉ. ΠΠΎΠ΅Ρ Π°Π»ΠΈ ΡΠ°ΡΠΊΠ°ΡΡΠ²Π°ΡΡ Π½Π°Ρ ΠΎΠ±ΡΠ°Π·.
ΠΠ΅ΡΠ΅Ρ ΠΎΠ΄ΠΈΠΌ Π² ΠΏΠ°ΠΏΠΊΡ:
cd /root/create-and-deploy-esxi/centos7
ΠΠ΅ΡΠ²ΡΠΌ Π΄Π΅Π»ΠΎΠΌ, ΡΠ΅Π΄Π°ΠΊΡΠΈΡΡΠ΅ΠΌ ΡΠ°ΠΉΠ» variables.tf. ΠΡΠΆΠ½ΠΎ ΡΠΊΠ°Π·Π°ΡΡ ΠΏΠΎΠ΄ΠΊΠ»ΡΡΠ΅Π½ΠΈΠ΅ ΠΊ ΡΠ΅ΡΠ²Π΅ΡΡ ESXi.
Π ΡΠ°ΠΉΠ»Π΅ network_config.cfg ΡΠΎΠ΄Π΅ΡΠΆΠ°ΡΡΡΡ ΡΠ΅ΡΠ΅Π²ΡΠ΅ Π½Π°ΡΡΡΠΎΠΉΠΊΠΈ Π±ΡΠ΄ΡΡΠ΅ΠΉ Π²ΠΈΡΡΡΠ°Π»ΡΠ½ΠΎΠΉ ΠΌΠ°ΡΠΈΠ½Ρ. ΠΠ΅Π½ΡΠ΅ΠΌ ΠΏΠΎΠ΄ ΡΠ²ΠΎΠΈ Π½ΡΠΆΠ΄Ρ ΠΈ Π·Π°ΠΏΡΡΠΊΠ°Π΅ΠΌ ΠΎΠ΄Π½ΠΎΡΡΡΠΎΡΠ½ΠΈΠΊ:
sed -i -e '2d' -e '3i "network": "'$(gzip < network_config.cfg| base64 | tr -d 'n')'",' metadata.json
ΠΡ ΠΈ Π² ΡΠ°ΠΉΠ»Π΅ main.tf ΠΌΠ΅Π½ΡΠ΅ΠΌ ΠΏΡΡΡ ΠΊ ova ΡΠ°ΠΉΠ»Ρ Π½Π° ΡΠ²ΠΎΠΉ, Π΅ΡΠ»ΠΈ ΠΎΡΠ»ΠΈΡΠ°Π΅ΡΡΡ.
ΠΠΎΠΌΠ΅Π½Ρ ΠΈΡΡΠΈΠ½Ρ.
terraform init
Initializing the backend...
Initializing provider plugins...
The following providers do not have any version constraints in configuration,
so the latest version was installed.
To prevent automatic upgrades to new major versions that may contain breaking
changes, it is recommended to add version = "..." constraints to the
corresponding provider blocks in configuration, with the constraint strings
suggested below.
* provider.esxi: version = "~> 1.6"
* provider.template: version = "~> 2.1"
Terraform has been successfully initialized!
You may now begin working with Terraform. Try running "terraform plan" to see
any changes that are required for your infrastructure. All Terraform commands
should now work.
If you ever set or change modules or backend configuration for Terraform,
rerun this command to reinitialize your working directory. If you forget, other
commands will detect it and remind you to do so if necessary.
terraform plan
Refreshing Terraform state in-memory prior to plan...
The refreshed state will be used to calculate this plan, but will not be
persisted to local or remote state storage.
data.template_file.Default: Refreshing state...
data.template_file.network_config: Refreshing state...
------------------------------------------------------------------------
An execution plan has been generated and is shown below.
Resource actions are indicated with the following symbols:
+ create
Terraform will perform the following actions:
# esxi_guest.Default will be created
+ resource "esxi_guest" "Default" {
+ boot_disk_size = (known after apply)
+ disk_store = "datastore1"
+ guest_name = "centos7-test"
+ guest_shutdown_timeout = (known after apply)
+ guest_startup_timeout = (known after apply)
+ guestinfo = {
+ "metadata" = "base64text"
+ "metadata.encoding" = "gzip+base64"
+ "userdata" = "base64text"
+ "userdata.encoding" = "gzip+base64"
}
+ guestos = (known after apply)
+ id = (known after apply)
+ ip_address = (known after apply)
+ memsize = "1024"
+ notes = (known after apply)
+ numvcpus = (known after apply)
+ ovf_properties_timer = (known after apply)
+ ovf_source = "/root/create-and-deploy-esxi/output-packer-centos7-x86_64/packer-centos7-x86_64.ova"
+ power = "on"
+ resource_pool_name = (known after apply)
+ virthwver = (known after apply)
+ network_interfaces {
+ mac_address = (known after apply)
+ nic_type = (known after apply)
+ virtual_network = "VM Network"
}
}
Plan: 1 to add, 0 to change, 0 to destroy.
------------------------------------------------------------------------
Note: You didn't specify an "-out" parameter to save this plan, so Terraform
can't guarantee that exactly these actions will be performed if
"terraform apply" is subsequently run.
Π€ΠΈΠ½ΠΈΡ:
terraform apply
ΠΡΠ»ΠΈ Π²ΡΡ ΡΠ΄Π΅Π»Π°Π½ΠΎ Π²Π΅ΡΠ½ΠΎ, ΡΠΎ ΡΠ΅ΡΠ΅Π· 2-3 ΠΌΠΈΠ½ΡΡΡ Π±ΡΠ΄Π΅Ρ ΡΠ°Π·Π²ΡΡΠ½ΡΡΠ° Π½ΠΎΠ²Π°Ρ Π²ΠΈΡΡΡΠ°Π»ΡΠ½Π°Ρ ΠΌΠ°ΡΠΈΠ½Π° ΠΈΠ· ΡΠ°Π½Π΅Π΅ ΡΠ΄Π΅Π»Π°Π½Π½ΠΎΠ³ΠΎ ΠΎΠ±ΡΠ°Π·Π°.
ΠΠ°ΡΠΈΠ°Π½ΡΡ ΠΈΡΠΏΠΎΠ»ΡΠ·ΠΎΠ²Π°Π½ΠΈΡ Π²ΡΠ΅Π³ΠΎ ΡΡΠΎΠ³ΠΎ, ΠΎΠ³ΡΠ°Π½ΠΈΡΠΈΠ²Π°ΡΡΡΡ ΡΠΎΠ»ΡΠΊΠΎ ΡΠ°Π½ΡΠ°Π·ΠΈΠ΅ΠΉ.
Π― Π²ΡΠ΅Π³ΠΎ Π»ΠΈΡΡ Ρ ΠΎΡΠ΅Π» ΠΏΠΎΠ΄Π΅Π»ΠΈΡΡΡΡ Π½Π°ΡΠ°Π±ΠΎΡΠΊΠ°ΠΌΠΈ ΠΈ ΠΏΠΎΠΊΠ°Π·Π°ΡΡ ΠΎΡΠ½ΠΎΠ²Π½ΡΠ΅ ΠΌΠΎΠΌΠ΅Π½ΡΡ ΠΏΡΠΈ ΡΠ°Π±ΠΎΡΠ΅ Ρ Π΄Π°Π½Π½ΡΠΌΠΈ ΠΏΡΠΎΠ΄ΡΠΊΡΠ°ΠΌΠΈ.
ΠΠ»Π°Π³ΠΎΠ΄Π°ΡΡ Π·Π° Π²Π½ΠΈΠΌΠ°Π½ΠΈΠ΅!
P.S.: Π±ΡΠ΄Ρ ΡΠ°Π΄ ΠΊΠΎΠ½ΡΡΡΡΠΊΡΠΈΠ²Π½ΠΎΠΉ ΠΊΡΠΈΡΠΈΠΊΠ΅.
ΠΡΡΠΎΡΠ½ΠΈΠΊ: habr.com