Docker Cookbook



Download 6,31 Mb.
Pdf ko'rish
bet154/260
Sana21.04.2022
Hajmi6,31 Mb.
#570749
1   ...   150   151   152   153   154   155   156   157   ...   260
Bog'liq
Docker Cookbook

for
s
in
sizes
if
s
.
id
==
SIZE_ID
][
0
]
image
=
[
i
for
i
in
images
if
i
.
id
==
IMAGE_ID
][
0
]
#Reads cloud config file
userdata
=
"\n"
.
join
(
open
(
'./cloud.cfg'
)
.
readlines
())
#Replace the name of the ssh key pair with yours
#You will need to open SSH port 22 on your default security group
6.9 Starting an Ubuntu Core Snappy Instance on AWS EC2 | 189


name
=
"snappy"
node
=
driver
.
create_node
(
name
=
name
,
image
=
image
,
size
=
size
,
\
ex_keyname
=
'snappy'
,
ex_userdata
=
userdata
)
print
node
.
extra
[
'network_interfaces'
]
If you want to use a different availability zone than 
EU_WEST
, you
will need to check the 
announcement
 for the correct AMI ID in
your preferred zone.
Discussion
Snappy is available in Beta on Amazon AWS, Google GCE, and Microsoft Azure, as
shown in 
Figure 6-1
.
Figure 6-1. Snappy Beta on public clouds
Follow the 
documentation
 to start an instance in these clouds by using the
command-line tools for each provider, or modify the Libcloud-based script provided.
For instance on Google GCE, once you have created an 
account
 and installed the
Cloud SDK
, you can start a Snappy instance with the GCE Cloud SDK:
$ gcloud compute instances create snappy-test \
--image-project ubuntu-snappy \
--image ubuntu-core-devel-v20141215 \
--metadata-from-file user-data=cloud.cfg
Created [https://www.googleapis.com/compute/v1/projects/runseb/zones/\
europe-west1-c/instances/snappy-test2].
NAME ZONE MACHINE_TYPE INTERNAL_IP EXTERNAL_IP STATUS
snappy-test2 europe-west1-c n1-standard-1 10.240.250.42 130.211.103.14 RUNNING

Download 6,31 Mb.

Do'stlaringiz bilan baham:
1   ...   150   151   152   153   154   155   156   157   ...   260




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©hozir.org 2024
ma'muriyatiga murojaat qiling

kiriting | ro'yxatdan o'tish
    Bosh sahifa
юртда тантана
Боғда битган
Бугун юртда
Эшитганлар жилманглар
Эшитмадим деманглар
битган бодомлар
Yangiariq tumani
qitish marakazi
Raqamli texnologiyalar
ilishida muhokamadan
tasdiqqa tavsiya
tavsiya etilgan
iqtisodiyot kafedrasi
steiermarkischen landesregierung
asarlaringizni yuboring
o'zingizning asarlaringizni
Iltimos faqat
faqat o'zingizning
steierm rkischen
landesregierung fachabteilung
rkischen landesregierung
hamshira loyihasi
loyihasi mavsum
faolyatining oqibatlari
asosiy adabiyotlar
fakulteti ahborot
ahborot havfsizligi
havfsizligi kafedrasi
fanidan bo’yicha
fakulteti iqtisodiyot
boshqaruv fakulteti
chiqarishda boshqaruv
ishlab chiqarishda
iqtisodiyot fakultet
multiservis tarmoqlari
fanidan asosiy
Uzbek fanidan
mavzulari potok
asosidagi multiservis
'aliyyil a'ziym
billahil 'aliyyil
illaa billahil
quvvata illaa
falah' deganida
Kompyuter savodxonligi
bo’yicha mustaqil
'alal falah'
Hayya 'alal
'alas soloh
Hayya 'alas
mavsum boyicha


yuklab olish