質問編集履歴

3

情報修正

2019/07/02 15:43

投稿

退会済みユーザー
test CHANGED
File without changes
test CHANGED
@@ -34,56 +34,56 @@
34
34
 
35
35
  vagrantfile内容
36
36
 
37
- # -*- mode: ruby -*-
37
+ -*- mode: ruby -*-
38
38
 
39
- # vi: set ft=ruby :
39
+ vi: set ft=ruby :
40
40
 
41
41
 
42
42
 
43
- # All Vagrant configuration is done below. The "2" in Vagrant.configure
43
+ All Vagrant configuration is done below. The "2" in Vagrant.configure
44
44
 
45
- # configures the configuration version (we support older styles for
45
+ configures the configuration version (we support older styles for
46
46
 
47
- # backwards compatibility). Please don't change it unless you know what
47
+ backwards compatibility). Please don't change it unless you know what
48
48
 
49
- # you're doing.
49
+ you're doing.
50
50
 
51
51
  Vagrant.configure("2") do |config|
52
52
 
53
- # The most common configuration options are documented and commented below.
53
+ The most common configuration options are documented and commented below.
54
54
 
55
- # For a complete reference, please see the online documentation at
55
+ For a complete reference, please see the online documentation at
56
56
 
57
- # https://docs.vagrantup.com.
57
+ https://docs.vagrantup.com.
58
58
 
59
59
 
60
60
 
61
- # Every Vagrant development environment requires a box. You can search for
61
+ Every Vagrant development environment requires a box. You can search for
62
62
 
63
- # boxes at https://vagrantcloud.com/search.
63
+ boxes at https://vagrantcloud.com/search.
64
64
 
65
65
  config.vm.box = "centos/7"
66
66
 
67
67
 
68
68
 
69
- # Disable automatic box update checking. If you disable this, then
69
+ Disable automatic box update checking. If you disable this, then
70
70
 
71
- # boxes will only be checked for updates when the user runs
71
+ boxes will only be checked for updates when the user runs
72
72
 
73
- # `vagrant box outdated`. This is not recommended.
73
+ `vagrant box outdated`. This is not recommended.
74
74
 
75
- # config.vm.box_check_update = false
75
+ config.vm.box_check_update = false
76
76
 
77
77
 
78
78
 
79
- # Create a forwarded port mapping which allows access to a specific port
79
+ Create a forwarded port mapping which allows access to a specific port
80
80
 
81
- # within the machine from a port on the host machine. In the example below,
81
+ within the machine from a port on the host machine. In the example below,
82
82
 
83
- # accessing "localhost:8080" will access port 80 on the guest machine.
83
+ accessing "localhost:8080" will access port 80 on the guest machine.
84
84
 
85
- # NOTE: This will enable public access to the opened port
85
+ NOTE: This will enable public access to the opened port
86
86
 
87
- # config.vm.network "forwarded_port", guest: 80, host: 8080
87
+ config.vm.network "forwarded_port", guest: 80, host: 8080
88
88
 
89
89
  macOS Sierra 10.12.6

2

情報修正

2019/07/02 15:43

投稿

退会済みユーザー
test CHANGED
File without changes
test CHANGED
@@ -26,327 +26,13 @@
26
26
 
27
27
 
28
28
 
29
- macOS Sierra 10.12.6
30
-
31
29
  VBoxManage -v 6.0.0r127566
32
30
 
33
31
  vagrant --version Vagrant 2.2.3
34
32
 
35
- vagrantfile内容
36
33
 
37
34
 
38
-
39
- There is a syntax error in the following Vagrantfile. The syntax error
40
-
41
- message is reproduced below for convenience:
42
-
43
-
44
-
45
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
46
-
47
- private network, which allows host-only access to the machi
48
-
49
- ^
50
-
51
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
52
-
53
- which allows host-only access to the machine
54
-
55
- ^
56
-
57
- HINOTORI-2:centos7 apple$ vagrant init centos/7
58
-
59
- Vagrant failed to initialize at a very early stage:
60
-
61
-
62
-
63
- There is a syntax error in the following Vagrantfile. The syntax error
64
-
65
- message is reproduced below for convenience:
66
-
67
-
68
-
69
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
70
-
71
- private network, which allows host-only access to the machi
72
-
73
- ^
74
-
75
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
76
-
77
- which allows host-only access to the machine
78
-
79
- ^
80
-
81
- HINOTORI-2:centos7 apple$ vagrant box remove CentOS7
82
-
83
- Vagrant failed to initialize at a very early stage:
84
-
85
-
86
-
87
- There is a syntax error in the following Vagrantfile. The syntax error
88
-
89
- message is reproduced below for convenience:
90
-
91
-
92
-
93
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
94
-
95
- private network, which allows host-only access to the machi
96
-
97
- ^
98
-
99
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
100
-
101
- which allows host-only access to the machine
102
-
103
- ^
104
-
105
- HINOTORI-2:centos7 apple$ vagrant box remove CentOS7
106
-
107
- Vagrant failed to initialize at a very early stage:
108
-
109
-
110
-
111
- There is a syntax error in the following Vagrantfile. The syntax error
112
-
113
- message is reproduced below for convenience:
114
-
115
-
116
-
117
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
118
-
119
- private network, which allows host-only access to the machi
120
-
121
- ^
122
-
123
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
124
-
125
- which allows host-only access to the machine
126
-
127
- ^
128
-
129
- HINOTORI-2:centos7 apple$ vagrant ssh
130
-
131
- Vagrant failed to initialize at a very early stage:
132
-
133
-
134
-
135
- There is a syntax error in the following Vagrantfile. The syntax error
136
-
137
- message is reproduced below for convenience:
138
-
139
-
140
-
141
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
142
-
143
- private network, which allows host-only access to the machi
144
-
145
- ^
146
-
147
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
148
-
149
- which allows host-only access to the machine
150
-
151
- ^
152
-
153
- HINOTORI-2:centos7 apple$ vagrant up
154
-
155
- Vagrant failed to initialize at a very early stage:
156
-
157
-
158
-
159
- There is a syntax error in the following Vagrantfile. The syntax error
160
-
161
- message is reproduced below for convenience:
162
-
163
-
164
-
165
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
166
-
167
- private network, which allows host-only access to the machi
168
-
169
- ^
170
-
171
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
172
-
173
- which allows host-only access to the machine
174
-
175
- ^
176
-
177
- HINOTORI-2:centos7 apple$ vagrant up
178
-
179
- Vagrant failed to initialize at a very early stage:
180
-
181
-
182
-
183
- There is a syntax error in the following Vagrantfile. The syntax error
184
-
185
- message is reproduced below for convenience:
186
-
187
-
188
-
189
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
190
-
191
- private network, which allows host-only access to the machi
192
-
193
- ^
194
-
195
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
196
-
197
- which allows host-only access to the machine
198
-
199
- ^
200
-
201
- HINOTORI-2:centos7 apple$ vagrant box add centos/7
202
-
203
- Vagrant failed to initialize at a very early stage:
204
-
205
-
206
-
207
- There is a syntax error in the following Vagrantfile. The syntax error
208
-
209
- message is reproduced below for convenience:
210
-
211
-
212
-
213
- /Users/apple/.Trash/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
214
-
215
- private network, which allows host-only access to the machi
216
-
217
- ^
218
-
219
- /Users/apple/.Trash/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
220
-
221
- which allows host-only access to the machine
222
-
223
- ^
224
-
225
- HINOTORI-2:centos7 apple$ vagrant box add centos/7
226
-
227
- Vagrant failed to initialize at a very early stage:
228
-
229
-
230
-
231
- There is a syntax error in the following Vagrantfile. The syntax error
232
-
233
- message is reproduced below for convenience:
234
-
235
-
236
-
237
- /Users/apple/.Trash/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
238
-
239
- private network, which allows host-only access to the machi
240
-
241
- ^
242
-
243
- /Users/apple/.Trash/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
244
-
245
- which allows host-only access to the machine
246
-
247
- ^
248
-
249
- HINOTORI-2:centos7 apple$ vagrant box add centos/7
250
-
251
- Vagrant failed to initialize at a very early stage:
252
-
253
-
254
-
255
- There is a syntax error in the following Vagrantfile. The syntax error
256
-
257
- message is reproduced below for convenience:
258
-
259
-
260
-
261
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
262
-
263
- private network, which allows host-only access to the machi
264
-
265
- ^
266
-
267
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
268
-
269
- which allows host-only access to the machine
270
-
271
- ^
272
-
273
- HINOTORI-2:centos7 apple$ vagrant box add centos/7
274
-
275
- Vagrant failed to initialize at a very early stage:
276
-
277
-
278
-
279
- There is a syntax error in the following Vagrantfile. The syntax error
280
-
281
- message is reproduced below for convenience:
282
-
283
-
284
-
285
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
286
-
287
- private network, which allows host-only access to the machi
288
-
289
- ^
290
-
291
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
292
-
293
- which allows host-only access to the machine
294
-
295
- ^
296
-
297
- HINOTORI-2:centos7 apple$ vagrant box add centos/7
298
-
299
- Vagrant failed to initialize at a very early stage:
300
-
301
-
302
-
303
- There is a syntax error in the following Vagrantfile. The syntax error
304
-
305
- message is reproduced below for convenience:
306
-
307
-
308
-
309
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
310
-
311
- private network, which allows host-only access to the machi
312
-
313
- ^
314
-
315
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
316
-
317
- which allows host-only access to the machine
318
-
319
- ^
320
-
321
- HINOTORI-2:centos7 apple$ vi Vagrantfile
35
+ vagrantfile内容
322
-
323
- HINOTORI-2:centos7 apple$ vagrant box add centos/7
324
-
325
- Vagrant failed to initialize at a very early stage:
326
-
327
-
328
-
329
- There is a syntax error in the following Vagrantfile. The syntax error
330
-
331
- message is reproduced below for convenience:
332
-
333
-
334
-
335
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
336
-
337
- private network, which allows host-only access to the machi
338
-
339
- ^
340
-
341
- /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
342
-
343
- which allows host-only access to the machine
344
-
345
- ^
346
-
347
- HINOTORI-2:centos7 apple$ vi Vagrantfile
348
-
349
-
350
36
 
351
37
  # -*- mode: ruby -*-
352
38
 
@@ -398,4 +84,6 @@
398
84
 
399
85
  # NOTE: This will enable public access to the opened port
400
86
 
401
- "Vagrantfile" 72L, 3091C
87
+ # config.vm.network "forwarded_port", guest: 80, host: 8080
88
+
89
+ macOS Sierra 10.12.6

1

情報修正

2019/07/02 14:17

投稿

退会済みユーザー
test CHANGED
File without changes
test CHANGED
@@ -1,22 +1,10 @@
1
- ### 前提・実現したいこと
2
-
3
-
4
-
5
-
6
-
7
1
  MacBookのターミナルで環境構築を行ってています。
8
2
 
9
3
  vagrantに接続しようとすると以下のエラーメッセージが発生しました。
10
4
 
11
5
 
12
6
 
13
- ### 発生している問題・エラーメッセージ
14
-
15
-
16
-
17
-
18
-
19
- エラーメッセージ
7
+ エラー
20
8
 
21
9
  syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
22
10
 
@@ -24,28 +12,390 @@
24
12
 
25
13
 
26
14
 
27
-
28
-
29
- ソースコード
15
+ ソース
30
16
 
31
17
  $ vagrant up
32
18
 
33
- $ vagrant ssh
34
-
35
- ### 試したこと
36
-
37
-
38
-
39
-
40
-
41
- vagrant,virtualボックスの削除、再インストール
42
-
43
-
44
-
45
-
46
-
47
- ### 補足情報(FW/ツールのバージョンなど)
48
-
49
-
50
-
51
- ここにより詳細な情報を記載してください。
19
+ $ vagrant ssh
20
+
21
+
22
+
23
+ 試したこと
24
+
25
+ vagrant,virtualボックス削除、再インストール
26
+
27
+
28
+
29
+ macOS Sierra 10.12.6
30
+
31
+ VBoxManage -v 6.0.0r127566
32
+
33
+ vagrant --version Vagrant 2.2.3
34
+
35
+ vagrantfile内容
36
+
37
+
38
+
39
+ There is a syntax error in the following Vagrantfile. The syntax error
40
+
41
+ message is reproduced below for convenience:
42
+
43
+
44
+
45
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
46
+
47
+ private network, which allows host-only access to the machi
48
+
49
+ ^
50
+
51
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
52
+
53
+ which allows host-only access to the machine
54
+
55
+ ^
56
+
57
+ HINOTORI-2:centos7 apple$ vagrant init centos/7
58
+
59
+ Vagrant failed to initialize at a very early stage:
60
+
61
+
62
+
63
+ There is a syntax error in the following Vagrantfile. The syntax error
64
+
65
+ message is reproduced below for convenience:
66
+
67
+
68
+
69
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
70
+
71
+ private network, which allows host-only access to the machi
72
+
73
+ ^
74
+
75
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
76
+
77
+ which allows host-only access to the machine
78
+
79
+ ^
80
+
81
+ HINOTORI-2:centos7 apple$ vagrant box remove CentOS7
82
+
83
+ Vagrant failed to initialize at a very early stage:
84
+
85
+
86
+
87
+ There is a syntax error in the following Vagrantfile. The syntax error
88
+
89
+ message is reproduced below for convenience:
90
+
91
+
92
+
93
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
94
+
95
+ private network, which allows host-only access to the machi
96
+
97
+ ^
98
+
99
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
100
+
101
+ which allows host-only access to the machine
102
+
103
+ ^
104
+
105
+ HINOTORI-2:centos7 apple$ vagrant box remove CentOS7
106
+
107
+ Vagrant failed to initialize at a very early stage:
108
+
109
+
110
+
111
+ There is a syntax error in the following Vagrantfile. The syntax error
112
+
113
+ message is reproduced below for convenience:
114
+
115
+
116
+
117
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
118
+
119
+ private network, which allows host-only access to the machi
120
+
121
+ ^
122
+
123
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
124
+
125
+ which allows host-only access to the machine
126
+
127
+ ^
128
+
129
+ HINOTORI-2:centos7 apple$ vagrant ssh
130
+
131
+ Vagrant failed to initialize at a very early stage:
132
+
133
+
134
+
135
+ There is a syntax error in the following Vagrantfile. The syntax error
136
+
137
+ message is reproduced below for convenience:
138
+
139
+
140
+
141
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
142
+
143
+ private network, which allows host-only access to the machi
144
+
145
+ ^
146
+
147
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
148
+
149
+ which allows host-only access to the machine
150
+
151
+ ^
152
+
153
+ HINOTORI-2:centos7 apple$ vagrant up
154
+
155
+ Vagrant failed to initialize at a very early stage:
156
+
157
+
158
+
159
+ There is a syntax error in the following Vagrantfile. The syntax error
160
+
161
+ message is reproduced below for convenience:
162
+
163
+
164
+
165
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
166
+
167
+ private network, which allows host-only access to the machi
168
+
169
+ ^
170
+
171
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
172
+
173
+ which allows host-only access to the machine
174
+
175
+ ^
176
+
177
+ HINOTORI-2:centos7 apple$ vagrant up
178
+
179
+ Vagrant failed to initialize at a very early stage:
180
+
181
+
182
+
183
+ There is a syntax error in the following Vagrantfile. The syntax error
184
+
185
+ message is reproduced below for convenience:
186
+
187
+
188
+
189
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
190
+
191
+ private network, which allows host-only access to the machi
192
+
193
+ ^
194
+
195
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
196
+
197
+ which allows host-only access to the machine
198
+
199
+ ^
200
+
201
+ HINOTORI-2:centos7 apple$ vagrant box add centos/7
202
+
203
+ Vagrant failed to initialize at a very early stage:
204
+
205
+
206
+
207
+ There is a syntax error in the following Vagrantfile. The syntax error
208
+
209
+ message is reproduced below for convenience:
210
+
211
+
212
+
213
+ /Users/apple/.Trash/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
214
+
215
+ private network, which allows host-only access to the machi
216
+
217
+ ^
218
+
219
+ /Users/apple/.Trash/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
220
+
221
+ which allows host-only access to the machine
222
+
223
+ ^
224
+
225
+ HINOTORI-2:centos7 apple$ vagrant box add centos/7
226
+
227
+ Vagrant failed to initialize at a very early stage:
228
+
229
+
230
+
231
+ There is a syntax error in the following Vagrantfile. The syntax error
232
+
233
+ message is reproduced below for convenience:
234
+
235
+
236
+
237
+ /Users/apple/.Trash/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
238
+
239
+ private network, which allows host-only access to the machi
240
+
241
+ ^
242
+
243
+ /Users/apple/.Trash/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
244
+
245
+ which allows host-only access to the machine
246
+
247
+ ^
248
+
249
+ HINOTORI-2:centos7 apple$ vagrant box add centos/7
250
+
251
+ Vagrant failed to initialize at a very early stage:
252
+
253
+
254
+
255
+ There is a syntax error in the following Vagrantfile. The syntax error
256
+
257
+ message is reproduced below for convenience:
258
+
259
+
260
+
261
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
262
+
263
+ private network, which allows host-only access to the machi
264
+
265
+ ^
266
+
267
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
268
+
269
+ which allows host-only access to the machine
270
+
271
+ ^
272
+
273
+ HINOTORI-2:centos7 apple$ vagrant box add centos/7
274
+
275
+ Vagrant failed to initialize at a very early stage:
276
+
277
+
278
+
279
+ There is a syntax error in the following Vagrantfile. The syntax error
280
+
281
+ message is reproduced below for convenience:
282
+
283
+
284
+
285
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
286
+
287
+ private network, which allows host-only access to the machi
288
+
289
+ ^
290
+
291
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
292
+
293
+ which allows host-only access to the machine
294
+
295
+ ^
296
+
297
+ HINOTORI-2:centos7 apple$ vagrant box add centos/7
298
+
299
+ Vagrant failed to initialize at a very early stage:
300
+
301
+
302
+
303
+ There is a syntax error in the following Vagrantfile. The syntax error
304
+
305
+ message is reproduced below for convenience:
306
+
307
+
308
+
309
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
310
+
311
+ private network, which allows host-only access to the machi
312
+
313
+ ^
314
+
315
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
316
+
317
+ which allows host-only access to the machine
318
+
319
+ ^
320
+
321
+ HINOTORI-2:centos7 apple$ vi Vagrantfile
322
+
323
+ HINOTORI-2:centos7 apple$ vagrant box add centos/7
324
+
325
+ Vagrant failed to initialize at a very early stage:
326
+
327
+
328
+
329
+ There is a syntax error in the following Vagrantfile. The syntax error
330
+
331
+ message is reproduced below for convenience:
332
+
333
+
334
+
335
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
336
+
337
+ private network, which allows host-only access to the machi
338
+
339
+ ^
340
+
341
+ /Users/apple/centos7/Vagrantfile:37: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
342
+
343
+ which allows host-only access to the machine
344
+
345
+ ^
346
+
347
+ HINOTORI-2:centos7 apple$ vi Vagrantfile
348
+
349
+
350
+
351
+ # -*- mode: ruby -*-
352
+
353
+ # vi: set ft=ruby :
354
+
355
+
356
+
357
+ # All Vagrant configuration is done below. The "2" in Vagrant.configure
358
+
359
+ # configures the configuration version (we support older styles for
360
+
361
+ # backwards compatibility). Please don't change it unless you know what
362
+
363
+ # you're doing.
364
+
365
+ Vagrant.configure("2") do |config|
366
+
367
+ # The most common configuration options are documented and commented below.
368
+
369
+ # For a complete reference, please see the online documentation at
370
+
371
+ # https://docs.vagrantup.com.
372
+
373
+
374
+
375
+ # Every Vagrant development environment requires a box. You can search for
376
+
377
+ # boxes at https://vagrantcloud.com/search.
378
+
379
+ config.vm.box = "centos/7"
380
+
381
+
382
+
383
+ # Disable automatic box update checking. If you disable this, then
384
+
385
+ # boxes will only be checked for updates when the user runs
386
+
387
+ # `vagrant box outdated`. This is not recommended.
388
+
389
+ # config.vm.box_check_update = false
390
+
391
+
392
+
393
+ # Create a forwarded port mapping which allows access to a specific port
394
+
395
+ # within the machine from a port on the host machine. In the example below,
396
+
397
+ # accessing "localhost:8080" will access port 80 on the guest machine.
398
+
399
+ # NOTE: This will enable public access to the opened port
400
+
401
+ "Vagrantfile" 72L, 3091C