31. $ vagrant up
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Box 'micropcf/base' could not be found. Attempting to find and install...
default: Box Provider: virtualbox
default: Box Version: 0.34.0
==> default: Loading metadata for box 'micropcf/base'
default: URL: https://atlas.hashicorp.com/micropcf/base
==> default: Adding box 'micropcf/base' (v0.34.0) for provider: virtualbox
default: Downloading: https://atlas.hashicorp.com/micropcf/boxes/base/versions/0.34.0/providers/virtualbox.box
==> default: Successfully added box 'micropcf/base' (v0.34.0) for 'virtualbox'!
==> default: Importing base box 'micropcf/base'...
==> default: Matching MAC address for NAT networking...
==> default: Checking if box 'micropcf/base' is up to date...
==> default: Setting the name of the VM: workspace_default_1454490175496_52031
==> default: Clearing any previously set network interfaces...
==> default: Preparing network interfaces based on configuration...
default: Adapter 1: nat
default: Adapter 2: hostonly
==> default: Forwarding ports...
default: 22 => 2222 (adapter 1)
==> default: Running 'pre-boot' VM customizations...
==> default: Booting VM...
==> default: Waiting for machine to boot. This may take a few minutes...
default: SSH address: 127.0.0.1:2222
default: SSH username: vagrant
default: SSH auth method: private key
default: Warning: Connection timeout. Retrying...
default: Vagrant insecure key detected. Vagrant will automatically replace
default: this with a newly generated keypair for better security.
default: Inserting generated public key within guest...
default: Removing insecure key from the guest if it's present...
default: Key inserted! Disconnecting and reconnecting using new SSH key...
==> default: Machine booted and ready!
==> default: Checking for guest additions in VM...
==> default: Configuring and enabling network interfaces...
==> default: Running provisioner: shell...
default: Running: inline script
==> default: stdin: is not a tty
==> default: Waiting for services to start...
==> default: MicroPCF is now running.
==> default: To begin using MicroPCF, please run:
==> default: cf api api.local.micropcf.io --skip-ssl-validation
==> default: cf login
==> default: Email: admin
==> default: Password: admin
※初回は vagrant box (3.5GB) を DL するので
時間がかかる???
2回目以降は2?3分で起動します。
33. API を target
$ cf api api.local.micropcf.io --skip-ssl-validation
Setting api endpoint to api.local.micropcf.io...
OK
API endpoint: https://api.local.micropcf.io (API version: 2.47.0)
Not logged in. Use 'cf login' to log in.
API の 向き先を決めてから???
34. Login
$ cf login
API endpoint: https://api.local.micropcf.io
Email> admin
Password> admin
Authenticating...
OK
user: admin password: admin
でログイン
35. 完了!
$ cf apps
Getting apps in org micropcf-org / space micropcf-space as admin...
OK
No apps found
以上で環境構築は終わりです
実際に使ってみましょう
← まだ何も deploy していないのでアプリは 0 個
39. $ cf push
(一部略)
Starting app hello-staticfile in org micropcf-org / space micropcf-space as admin...
Downloading staticfile_buildpack...
Downloaded staticfile_buildpack (2.4M)
Creating container
Successfully created container
Downloading app package...
Downloaded app package (250B)
Staging...
-------> Buildpack version 1.3.0
Downloaded [file:///tmp/buildpacks/c0c5c5b5e08bd4e125c760d54f11e0ea/dependencies/https___pivotal-buildpacks.s3.amazonaws.com_concourse-binaries_nginx_nginx-1.9.9-
linux-x64.tgz]
grep: Staticfile: No such file or directory
-----> Using root folder
-----> Copying project files into public/
-----> Setting up nginx
grep: Staticfile: No such file or directory
Exit status 0
Staging complete
Uploading droplet, build artifacts cache...
Uploading droplet...
Uploading build artifacts cache...
Uploaded build artifacts cache (128B)
Uploaded droplet (2.4M)
Uploading complete
1 of 1 instances running
App started
OK
App hello-staticfile was started using this command `sh boot.sh`
Showing health and status for app hello-staticfile in org micropcf-org / space micropcf-space as admin...
OK
requested state: started
instances: 1/1
usage: 1G x 1 instances
urls: hello-staticfile.local.micropcf.io
last uploaded: Wed Feb 3 09:42:16 UTC 2016
stack: cflinuxfs2
buildpack: staticfile_buildpack
state since cpu memory disk details
#0 running 2016-02-03 06:42:27 PM 0.0% 0 of 1G 0 of 1G
40. $ cf push
(一部略)
Starting app hello-staticfile in org micropcf-org / space micropcf-space as admin...
Downloading staticfile_buildpack...
Downloaded staticfile_buildpack (2.4M)
Creating container
Successfully created container
Downloading app package...
Downloaded app package (250B)
Staging...
-------> Buildpack version 1.3.0
Downloaded [file:///tmp/buildpacks/c0c5c5b5e08bd4e125c760d54f11e0ea/dependencies/https___pivotal-buildpacks.s3.amazonaws.com_concourse-binaries_nginx_nginx-1.9.9-
linux-x64.tgz]
grep: Staticfile: No such file or directory
-----> Using root folder
-----> Copying project files into public/
-----> Setting up nginx
grep: Staticfile: No such file or directory
Exit status 0
Staging complete
Uploading droplet, build artifacts cache...
Uploading droplet...
Uploading build artifacts cache...
Uploaded build artifacts cache (128B)
Uploaded droplet (2.4M)
Uploading complete
1 of 1 instances running
App started
OK
App hello-staticfile was started using this command `sh boot.sh`
Showing health and status for app hello-staticfile in org micropcf-org / space micropcf-space as admin...
OK
requested state: started
instances: 1/1
usage: 1G x 1 instances
urls: hello-staticfile.local.micropcf.io
last uploaded: Wed Feb 3 09:42:16 UTC 2016
stack: cflinuxfs2
buildpack: staticfile_buildpack
state since cpu memory disk details
#0 running 2016-02-03 06:42:27 PM 0.0% 0 of 1G 0 of 1G ※約20秒
アプリを
自動的に
動かして???
URLを発行