On Tue, Jun 16, 2020 at 3:40 PM Craig Russell <apache....@gmail.com> wrote: > > > On Jun 16, 2020, at 12:21 PM, Sam Ruby <ru...@intertwingly.net> wrote: > > > > On Tue, Jun 16, 2020 at 3:00 PM Craig Russell <apache....@gmail.com> wrote: > >> > >> I've run setupmymac many times and it always ends starting the httpd > >> server and then calling my browser to display localhost which just hangs. > > > > What it should do is open your browser to display > > http://whimsy.local/. > > It does that. > > > What you should see should look like what you > > see when you go to https://whimsy.apache.org/ > > It hangs forever. > > > >> I can restart the server via sudo apachectl restart and it all appears to > >> go well.
What do you mean by "all appears to go well"? Try running "tail -f /var/log/apache2/error_log" in one window and then "sudo apachectl restart" in another. What do you see in your error_log? If that works, try "curl localhost". > >> What I cannot figure out is what the httpd server is servicing and how to > >> talk to it. > > > > You should have a file on your machine by the name of > > /private/etc/apache2/other/whimsy.conf. > > There is that file. > > > In that file you should see: > > > > <VirtualHost *:80> > > ServerName whimsy.local > > > > ## Vhost docroot > > DocumentRoot "/srv/whimsy/www" > > > Both of these entries are there. > > > This tells Apache httpd to serve requests for http://whimsy.local/ > > from /srv/whimsy/www. > > Where is this configured? /etc/apache2/httpd.conf should contain a line: Include /private/etc/apache2/other/*.conf > > Later in that file you should see ErrorLog and CustomLog directives. > > Both are set to /var/log/apache2/whimsy_error.log The second should be "/var/log/apache2/whimsy_access.log" > > They tell Apache httpd where to place logs. These logs will contain > > useful information concerning access attempts and errors. > > The log file was last written to in May 2020. That's useful information. It indicates that whimsy configuration file wasn't loaded for some reason. Hopefully /var/log/apache2/error_log provides some insight as to why. > In /Users/clr/apache/git/whimsy I ran config/setupmymac and got no errors and > it then opened whimsy.local in a browser and there is nothing in > whimsy_error.log. > > Craig - Sam Ruby > >> Maybe I'm reading the wrong part of SETUPMYMAC.md? Where does it say which > >> url and which port and how to run a .cgi? Do I have to be in a specific > >> directory when I run the scripts? > >> > >> Thanks, > >> Craig > > > > - Sam Ruby > > > >>> On Jun 15, 2020, at 5:57 PM, Sam Ruby <ru...@intertwingly.net> wrote: > >>> > >>> On Mon, Jun 15, 2020 at 7:50 PM Craig Russell <apache....@gmail.com> > >>> wrote: > >>>> > >>>> Thanks for that. Now, to test this thing. > >>>> > >>>> I didn't find any way to do local testing of a cgi script in the > >>>> officers' or members' area of whimsy/www. (I'm currently using rackup to > >>>> test the roster-emeritus code). > >>> > >>> Either of the following will set you up to be able to run cgi scripts > >>> locally: > >>> > >>> https://github.com/apache/whimsy/blob/master/SETUPMYMAC.md > >>> https://github.com/apache/whimsy/blob/master/MACOSX.md > >>> > >>>> So is the best approach here to simply create the coi.cgi in > >>>> www/officers/ and test using the live instance? If so, do I have to wait > >>>> for Godot each time I commit code until something catches up? > >>> > >>> Best approach is to invest the time to get things working locally. > >>> > >>> Second best approach is running the CGI scripts from the command line. > >>> Example: > >>> > >>> ruby www/members/proxy.cgi proxy="Sam%20Ruby" > >>> > >>> Third best approach is to test using the live instance. Things are > >>> set up to auto-deploy. Best case for CGI scripts is that this happens > >>> in seconds. Taking a minute or three, however, is not uncommon. > >>> Worst case, installation happens the next time puppet runs, which, if > >>> I remember correctly, is every half hour. > >>> > >>>> Thanks, > >>>> Craig > >>> > >>> - Sam Ruby > >>> > >>>>> On Jun 12, 2020, at 2:00 PM, Sam Ruby <ru...@intertwingly.net> wrote: > >>>>> > >>>>> $:.unshift '/srv/whimsy/lib' > >>>>> require 'whimsy/asf' > >>>>> > >>>>> committees = ASF::Committee.officers + ASF::Committee.nonpmcs > >>>>> > >>>>> chairs = committees.map do |committee| > >>>>> committee.chairs.map {|chair| chair[:id]} > >>>>> end > >>>>> > >>>>> ids = (chairs.flatten + ASF::Service['board'].members.map(&:id)).uniq > >>>>> > >>>>> puts ids.map {|id| ASF::Person.find(id)}. > >>>>> sort_by {|person| person.public_name.split.rotate(-1)}. > >>>>> map {|person| person.public_name} > >>>>> > >>>>> - Sam Ruby > >>>>> > >>>>> On Tue, Jun 9, 2020 at 1:05 AM Craig Russell <apache....@gmail.com> > >>>>> wrote: > >>>>>> > >>>>>> Here's how I'd like to have the COI affirmation tool work. Once the > >>>>>> discussion here nears consensus, I'll share the plan with the board. > >>>>>> Unless anyone thinks that the tool should have a wider discussion on > >>>>>> board@... > >>>>>> > >>>>>> The tool is protected by officer login and the credentials are sent to > >>>>>> the server so that only officers can see the results. > >>>>>> > >>>>>> The tool executes one GET to retrieve: > >>>>>> - the current COI document from > >>>>>> foundation/officers/COI/fy2020/template.txt > >>>>>> - the current list of officers who are required to affirm their > >>>>>> agreement with the COI foundation/officers/COI/fy2020/signatories.txt > >>>>>> - the current list of officers and their status (whether they have > >>>>>> already affirmed) > >>>>>> > >>>>>> If the user is required to affirm, and has not done so already, the > >>>>>> current COI document modified with the officer's availid and date is > >>>>>> presented to the officer in a scroll window along with two buttons: > >>>>>> (Cancel) and (Affirm) > >>>>>> > >>>>>> If the user is not required to affirm, or has already done so, or > >>>>>> (Cancel) is pressed, the list of officers and their signing status is > >>>>>> displayed. > >>>>>> > >>>>>> If Affirm is pressed: > >>>>>> - the officer's availid and timestamp is sent to the server via POST > >>>>>> - POST processing: > >>>>>> -- the COI document with the officer's availid and date is written to > >>>>>> the file called foundation/officers/COI/fy2020/availid.txt > >>>>>> -- the list of officers and their signing status is displayed > >>>>>> > >>>>>> Open questions: > >>>>>> - how to manage the list of officers required to affirm? one > >>>>>> possibility is to create a file: > >>>>>> foundation/officers/COI/fy2020/officers.txt which is created by > >>>>>> secretary/chair at the beginning of each fiscal year. > >>>>>> > >>>>>> - is officer credentials sufficient for the purpose of this tool, or > >>>>>> should the tool be restricted to those officers required to affirm? > >>>>>> > >>>>>> Feedback? > >>>>>> > >>>>>> Craig Russell > >>>>>> Director, Apache Board > >>>>>> apache....@gmail.com > >>>>>> > >>>>>> > >>>>>> > >>>>>> > >>>> > >>>> Craig L Russell > >>>> c...@apache.org > >>>> > >> > >> Craig L Russell > >> c...@apache.org > >> > > Craig L Russell > c...@apache.org >