Im using PHP buildpack https://github.com/cloudfoundry/php-buildpack for CloudFoundry. The app bring up a dummy HTTPD webserver directing traffic to defined endpoint.
In .bp-config/options.json, i could see HTTPD_MODULES_STRIP.
What does this option accomplish? Setting true or false, resulted in the same outcome. So curious, how is it being used?
If the extension has to be written to consume that option, how do i do that?
version of HTTPD 2.4.12
When modules specified in your build manifest are zipped, setting HTTPD_MODULES_STRIP to true will cause the first element of the archived file's path to be stripped before placing it in the destination directory.
Example when HTTPD_MODULES_STRIP = true: When extracting file archive.txt into destination directory intoDir, directory "some" is removed from the resulting pathname.
some/file/in/archive.txt -> intoDir/file/in/archive.txt
See ./lib/build_pack_utils/builder.py line 312 and ./lib/build_pack_utils/zips.py for more info.
Related
I am running SRS from a Docker container. On Manjaro I can issue a docker command in terminal, and stream video from OBS to the SRS instance I just launched. I can then view live video in a web page, from that server.
BUT!
The configuration is a bit opaque. The config files refer to a directory ("./objs") that is likely defined in a config file, but I can't find it.
AND!
I'm still a bit confused about how Docker works- isn't there a straightforward way to edit an image or container?
I can see all the config files in /etc/srs (like srs.conf, rtmp.conf and so on). The config files refer to the directory ./objs for the location of (for instance) the nginx root, index.html. But I cannot find that directory.
I also have installed SRS from official repos, on the same machine. I launched srs from /usr/bin/srs (not from the Docker image), but it immediately quits. So I gave up for now. Running it from Docker seems to work pretty well.
When start SRS by docker, it actually the same to start in shell:
cd /usr/local/srs && ./objs/srs -c conf/srs.conf
You can also use docker inspect ossrs/srs:5 to get the information:
"Cmd": ["./objs/srs", "-c", "conf/srs.conf"],
"WorkingDir": "/usr/local/srs",
The current work directory is /usr/local/srs, so ./objs is /usr/local/srs/objs, and I will describe more about why relative directories.
The configuration file is conf/srs.conf, which is actually /usr/local/srs/conf/srs.conf, and there are lots of configuration examples in ./conf.
The examples in ossrs.io is in the same format, uses a configuration and depends on the work directory.
SRS uses relative directory ./objs or ./conf because there are some features depend on it. You can see full.conf for all the configurations that supported.
We use relative directory because you can easily change to other directory, or start more than one SRS server. Of course, you could change the relative directory to abolute directory, please search ./objs in full.conf, for example:
pid ./objs/srs.pid;
ff_log_dir ./objs;
srs_log_file ./objs/srs.log;
http_server {
dir ./objs/nginx/html;
}
vhost __defaultVhost__ {
hls {
hls_path ./objs/nginx/html;
}
Please note that you can use docker volume to mount directory of host for container.
setting up a distributed test with Jmeter i ended up in this problem.
First of all i'm aware setting the jmeter.property server.rmi.ssl.disable=true is a work around.
Still i'd like to see if it is possible to use this rmi_keystore.jks. The Jmeter documentation
https://jmeter.apache.org/usermanual/remote-test.html is clear enough about setting up the environment but doesn't mention at all how specify the path to the rmi_keystore.jks, or if this has to be the rmi_keystore.jks on the worker or the one in the controller.
I noticed if you do a test on your machine as worker and controller ( as this guy does https://www.youtube.com/watch?v=Ok8Cqc0wipk ) setting the absolute path to the rmi_keystore.jks works.
Ex. server.rmi.ssl.truststore.file=C:\path\to\the\rmi_keystore.jks and server.rmi.ssl.keystore.file=C:\path\to\the\rmi_keystore.jks and.
But this doesn't work when controller has a different path to the rmi_keystore.jks then the worker.
My question is : how can I set the right jmeter properties server.rmi.ssl.truststore.file and server.rmi.ssl.keystore.file to resolve the FileNotFoundException? Stating that default values don't work?
thank you everyone
You need to:
Generate the rmi_keystore.jks file on the master machine
Copy it to all the slaves
The default location (where JMeter looks for the file) is rmi_keystore.jks, to wit if you drop it to "bin" folder of your JMeter installation on master and slaves - JMeter will find it and start using.
The server.rmi.ssl.keystore.file property should be used if you want to customize the file name and/or location so if it is different you can either set slave-specific location via user.properties file or pass it via -J command-line argument.
If location is common for all the slaves and you want to override it in a single shot - provide it via -G command-line argument.
More information:
Configuring JMeter
Full list of command-line options
Apache JMeter Properties Customization Guide
You can use create-rmi-keystore.bat to generate the rmi_keystore.jks. You will find it under Bin folder.
So I just created a new project using the command:
laravel new blog
Then I started by changing the directory and do the command
php artisan serve
And this is what happened, more details:
I'm using laravel 8.0.1 (latest version)
I haven't run any command except the one I listed above
I'm using windows
I even updated the php to 7.4.10 (latest ver)
I came across the same issue.
This was how how I solved mine:
Goto the main PHP part, I mean the installed PHP from official website.
Look out for a folder named php.ini-development
Duplicate this file.
Then rename the copy to php.ini
Go back to your laravel project folder and rerun php artisan serve
PS: If there is any additional steps you took, you can as well comment them below:
XOXO
So actually i dont actually know what the reason is, but using the php -S localhost:8000 -t public
Check your PHP version in your local server and System variable path. Make sure they are using the same PHP version
I had this problem too, and I solved it in this way:
set: php.ini
variables_order = "GPCS"
This error is because the php.ini was not found.
run php --ini
Configuration File (php.ini) Path:
Loaded Configuration File: C:\php8\php.ini
Scan for additional .ini files in: (none)
Additional .ini files parsed: (none)
The line "Loaded Configuration File" would indicate the location of loaded php.ini, if not, rename the php.ini-development to php.ini
I am using on apache solr3.6 (naive user) and have data in the multicore of solr folder.
D:\setup\apache-solr-3.6.0\example\multicore
The current version of tomcat I am using has startup.bat in its bin folder so I specified JAVA_OPTS in it as below:
rem Get remaining unshifted command line arguments and save them in the
set CMD_LINE_ARGS=
:setArgs
if ""%1""=="""" goto doneSetArgs
set CMD_LINE_ARGS=%CMD_LINE_ARGS% %1
shift
goto setArgs
:doneSetArgs
set "JAVA_OPTS=%JAVA_OPTS% -Dsolr.solr.home=D:\setup\apache-solr-3.6.0\example\multicore"
call "%EXECUTABLE%" start %CMD_LINE_ARGS%
:end
However I recently downloaded a new version of tomcat which contains no startup.bat in it but some .exe file (may be tomcat.exe) instead, double clicking which will start the tomcat server.
So how do I specify JAVA_OPTS and -Dsolr now?
As #Bhanu said...
Go to tomcat istallation folder, inside Apache Software Foundation\Tomcat 6.0\bin you'll find tomcat6w.exe run it. It will open tomcat configuration window
Open java tab and specify the multicore path inside java options as -Dsolr.solr.home=D:\setup\apache-solr-3.6.0\example\multicore
For setting up Solr Home option with Tomcat refer to details.
Also, more information would be available at SolrTomcat
In newer versions of tomcat say tomcat7, you will find tomcat7w.exe in tomcat/bin. Run it select Java tab and in Java Options pane write your path.
It is quite easy compared to JNDI way.
My webapp is having an issue since upgrading to Tomcat 7. My session will go null after I login and try to do anything (submitting a request). I've read that setting the following may help:
org.apache.tomcat.util.http.ServerCookie.FWD_SLASH_IS_SEPARATOR=false
Does anyone know where to set this? Should this be set in web.xml, context.xml or somewhere else?
The other thing I want to check is the following:
org.apache.catalina.STRICT_SERVLET_COMPLIANCE
You can set any of the system properties in
apache-tomcat-7.0.33\conf\catalina.properties
file. Adding your entry in this file should resolve your problem.
E.g.
environment=local
You can set system properties in Tomcat by creating a setenv.sh file in /bin directory.
I did the following to set the system properties.
export JAVA_OPTS="-Dmyprojectvar.subname=value -Danothervariable=value -Danother.variable=value"
Remember:
There is no space between the export JAVA_OPTS and =. Also: the symbol & is different, use ..
Now, run your catalina.sh to start tomcat.
You can set these system properties in command line that starts Tomcat. For example, you can have file setenv.bat (on setenv.sh if you are on linux) in Tomcats bin folder with following content:
set "CATALINA_OPTS=%CATALINA_OPTS% -Dfile.encoding=UTF8 -Dorg.apache.catalina.STRICT_SERVLET_COMPLIANCE=true -Duser.timezone=GMT -Xmx1024m -XX:MaxPermSize=256m"
This file is preferred way of setting properties for Tomcat.
Now, FWD_SLASH_IS_SEPARATOR is by default set to false. If you set STRICT_SERVLET_COMPLIANCE to true, the value of FWD_SLASH_IS_SEPARATOR will be also set to true (and values of some other properties). However, you can set it explicitly to false, e.g. using the following in your setenv file is fine:
-Dorg.apache.catalina.STRICT_SERVLET_COMPLIANCE=true
-Dorg.apache.tomcat.util.http.ServerCookie.FWD_SLASH_IS_SEPARATOR=false
This is also what I suggest when someone sets STRICT_SERVLET_COMPLIANCE to true, to always disable the FWD_SLASH_IS_SEPARATOR. Otherwise, the cookie Path value will be sent quoted (e.g. "\") and all browsers as of today, except Opera, do not recognize this and would e.g. fail to track the session.
THE SOLUTION:
sessionCookiePathUsesTrailingSlash="false"
We actually figured out how to solve this. It was a Tomcat 7 setting we needed to set. We placed it in server.xml, under the tag as follows:
<Context path="/test" reloadable="true" docBase="c:\webapp\test"
workDir="c:\webapp\test" sessionCookiePathUsesTrailingSlash="false"/>
When we were debugging the problem and looking at the cookies path we noticed it was putting a \ backslash after the webapp name, so for our test webapp it was setting the path to /test/ instead of /test. This caused a bunch of problems.
Has anyone else had to deal with this setting in Tomcat 7? Or have a similar problem?
If you are trying to set variables for a server running in eclipse:
Select Run > Run Configurations
Make sure your server is selected
Select Environment Tab
Click 'New' to add a new variable