Skip to content

Commit b5c7b21

Browse files
committed
create vagrant for prod env
1 parent 230dcf4 commit b5c7b21

10 files changed

Lines changed: 54 additions & 0 deletions

File tree

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{"dependencies":[["iniparse",["~> 1.4",">= 1.4.2"]],["webrick",[">= 0"]],["xmlrpc",[">= 0"]],["formatador",["~> 0.2"]],["excon",["~> 0.58"]],["builder",[">= 0"]],["fog-core",["~> 1.45"]],["racc",["~> 1.4"]],["nokogiri",[">= 1.5.11","< 2.0.0"]],["fog-xml",["~> 0.1.1"]],["fog-xenserver",[">= 0"]],["optimist",["~> 3.0"]],["json",["~> 2.0"]],["rbvmomi2",["~> 3.0"]],["fog-vsphere",[">= 0.4.0"]],["fog-voxel",[">= 0"]],["CFPropertyList",["~> 2.2"]],["fission",[">= 0"]],["fog-vmfusion",[">= 0"]],["fog-terremark",[">= 0"]],["multi_json",["~> 1.10"]],["fog-json",[">= 0"]],["fog-storm_on_demand",[">= 0"]],["fog-softlayer",[">= 0"]],["fog-serverlove",[">= 0"]],["fog-sakuracloud",[">= 0.0.4"]],["fog-riakcs",[">= 0"]],["fog-radosgw",[">= 0.0.2"]],["ipaddress",["~> 0.5"]],["fog-rackspace",[">= 0"]],["fog-profitbricks",[">= 0"]],["fog-powerdns",[">= 0.1.1"]],["ovirt-engine-sdk",[">= 4.3.1"]],["benchmark",[">= 0.3"]],["uri",[">= 0.13.1"]],["securerandom",[">= 0.3"]],["logger",[">= 1.4.2"]],["bigdecimal",[">= 0"]],["ruby2_keywords",[">= 0"]],["drb",[">= 0"]],["base64",[">= 0"]],["minitest",[">= 5.1"]],["connection_pool",[">= 2.2.5"]],["concurrent-ruby",["~> 1.0",">= 1.3.1"]],["tzinfo",["~> 2.0",">= 2.0.5"]],["i18n",[">= 1.6","< 2"]],["activesupport",[">= 0"]],["fog-ovirt",[">= 0"]],["fog-openstack",[">= 0"]],["fog-local",[">= 0"]],["fog-joyent",[">= 0"]],["fog-internet-archive",[">= 0"]],["fog-google",["<= 0.1.0"]],["fog-ecloud",["~> 0.1"]],["fog-dynect",["~> 0.0.2"]],["fog-dnsimple",["~> 1.0"]],["fog-digitalocean",[">= 0.3.0"]],["fog-cloudatcost",["~> 0.1.0"]],["mime-types-data",["~> 3.2015"]],["mime-types",[">= 0"]],["dry-inflector",[">= 0"]],["fog-brightbox",["~> 0.4"]],["fog-aws",[">= 0.6.0"]],["fog-atmos",[">= 0"]],["strscan",[">= 0"]],["rexml",[">= 0"]],["xml-simple",["~> 1.1"]],["netrc",["~> 0.8"]],["domain_name",["~> 0.5"]],["http-cookie",[">= 1.0.2","< 2.0"]],["http-accept",[">= 1.7.0","< 2.0"]],["rest-client",["~> 2.0"]],["aliyun-sdk",["~> 0.8.0"]],["public_suffix",[">= 2.0.2","< 7.0"]],["addressable",["~> 2.8.0"]],["fog-aliyun",[">= 0.1.0"]],["fog",["~> 1.22"]],["vagrant-aws",["= 0.7.2"]]],"checksum":"b088b7c6a510045a3920616eaecefb98bf2df989113ac5e6fbd783a0075cce86","vagrant_version":"2.4.2"}
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
1.5:i-07d4a70e9bb74ca16
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{"name":"dummy","version":"0","provider":"aws","directory":"boxes/dummy/0/aws"}
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
1000
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
i-07d4a70e9bb74ca16
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
6311062a0f0b4353b675f78a3a04dfc5
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{"rsync":{"/vagrant":{"guestpath":"/vagrant","hostpath":"/home/ubuntu/Flask-REST-API/vagrant","disabled":false,"__vagrantfile":true,"owner":"ubuntu","group":"ubuntu"}}}
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/home/ubuntu/Flask-REST-API/vagrant
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# Copyright (c) HashiCorp, Inc.
2+
# SPDX-License-Identifier: BUSL-1.1
3+
4+
# This file loads the proper rgloader/loader.rb file that comes packaged
5+
# with Vagrant so that encoded files can properly run with Vagrant.
6+
7+
if ENV["VAGRANT_INSTALLER_EMBEDDED_DIR"]
8+
require File.expand_path(
9+
"rgloader/loader", ENV["VAGRANT_INSTALLER_EMBEDDED_DIR"])
10+
else
11+
raise "Encoded files can't be read outside of the Vagrant installer."
12+
end

vagrant/Vagrantfile

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
# -*- mode: ruby -*-
2+
# vi: set ft=ruby :
3+
4+
require 'vagrant-aws'
5+
6+
Vagrant.configure("2") do |config|
7+
config.vm.box = "dummy"
8+
9+
config.vm.provider "aws" do |aws, override|
10+
# AWS credentials
11+
aws.access_key_id = ENV['AWS_ACCESS_KEY_ID']
12+
aws.secret_access_key = ENV['AWS_SECRET_ACCESS_KEY']
13+
14+
# AWS region and AMI
15+
aws.region = "us-east-1"
16+
aws.ami = "ami-054d6a336762e438e"
17+
18+
# Instance type
19+
aws.instance_type = "t3.small"
20+
21+
# Key pair for SSH
22+
aws.keypair_name = "api-server"
23+
override.ssh.username = "ubuntu"
24+
override.ssh.private_key_path = File.expand_path("api-server.pem", __dir__)
25+
26+
# Network settings
27+
aws.subnet_id = "subnet-0a03e0dbddc93b6aa"
28+
aws.associate_public_ip = true
29+
aws.security_groups = ["sg-09d4c5f5679711dd2"]
30+
31+
# Do not terminate instance on shutdown
32+
aws.terminate_on_shutdown = false
33+
end
34+
end

0 commit comments

Comments
 (0)