Where is apache.conf?

366 views
Skip to first unread message

realtebo

unread,
May 18, 2017, 5:14:56 AM5/18/17
to Vagrant
I'm looking at this web page: https://www.vagrantup.com/docs/synced-folders/virtualbox.html

I need to change apache.conf (or httpd.conf).

Where is this file in a Vagrant box ?

(Sorry, i'm  total newbie)

I tried these searches  but none found...

vagrant@homestead:/$ sudo find . -name httpd.conf
vagrant@homestead:/
$ sudo find . -name apache.conf
vagrant@homestead
:/$ sudo find . -name apache.*
./
usr/share/vim/vim74/syntax/apache.vim
./usr/share/sosreport/sos/plugins/__pycache__/apache.cpython-35.pyc
./usr/share/sosreport/sos/plugins/apache.py

Alvaro Miranda Aguilera

unread,
May 18, 2017, 6:21:55 AM5/18/17
to vagra...@googlegroups.com
Hello

You need to install the package first

ie

apt-get update
apt-get install -y httpd  (not sure the right name)

Alvaro

--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vagrant-up+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/2829455a-b138-4648-806c-22a50657b9b3%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Alvaro

realtebo

unread,
May 18, 2017, 11:15:06 AM5/18/17
to Vagrant
I actually have 'some' running webserver because I'm using Homestead to command Vagrant, for developing with Laravel framework.

Probably is there another web server used by Homestead+Vagrant?


This my vagrantfile

# -*- mode: ruby -*-
# vi: set ft=ruby :

require 'json'
require 'yaml'

VAGRANTFILE_API_VERSION ||= "2"
confDir = $confDir ||= File.expand_path(File.dirname(__FILE__))

homesteadYamlPath = confDir + "/Homestead.yaml"
homesteadJsonPath = confDir + "/Homestead.json"
afterScriptPath = confDir + "/after.sh"
aliasesPath = confDir + "/aliases"

require File.expand_path(File.dirname(__FILE__) + '/scripts/homestead.rb')

Vagrant.require_version '>= 1.9.0'

Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
    if File.exist? aliasesPath then
        config.vm.provision "file", source: aliasesPath, destination: "/tmp/bash_aliases"
        config.vm.provision "shell" do |s|
            s.inline = "awk '{ sub(\"\r$\", \"\"); print }' /tmp/bash_aliases > /home/vagrant/.bash_aliases"
        end
    end

    if File.exist? homesteadYamlPath then
        settings = YAML::load(File.read(homesteadYamlPath))
    elsif File.exist? homesteadJsonPath then
        settings = JSON.parse(File.read(homesteadJsonPath))
    else
        abort "Homestead settings file not found in #{confDir}"
    end

    Homestead.configure(config, settings)

    if File.exist? afterScriptPath then
        config.vm.provision "shell", path: afterScriptPath, privileged: false
    end

    if defined? VagrantPlugins::HostsUpdater
        config.hostsupdater.aliases = settings['sites'].map { |site| site['map'] }
    end
end


And this my Homestead file

---
ip: "192.168.192.33"
memory: 2048
cpus: 2
provider: virtualbox

authorize: ~/.ssh/id_rsa.pub

keys:
    - ~/.ssh/id_rsa

folders:
    - map: C:\Users\realtebo\Downloads\LaravelCode
      to: /home/vagrant/Code

sites:
    - map: my.app
      to: /home/vagrant/Code/my_app/public

databases:
    - my_app_db

To unsubscribe from this group and stop receiving emails from it, send an email to vagrant-up+...@googlegroups.com.



--
Alvaro

realtebo

unread,
May 19, 2017, 3:41:09 AM5/19/17
to Vagrant
I resolved without touching Vagrant box configs.

My issue was related to autocompiling and reloading of assets under Homestead/Vagrant/Laravel development.

I resolved just applying this tips

You may find that in certain environments Webpack isn't updating when your files change. If this is the case on your system, consider using the watch-poll command:
npm run watch-poll

Reply all
Reply to author
Forward
0 new messages