Response stringlengths 15 2k | Instruction stringlengths 37 2k | Prompt stringlengths 14 160 |
|---|---|---|
No. The private key remains at the owner's end. Otherwise it wouldn't be private. | Is it possible to fetch the private key of an SSL certificate using some SSL socket connetion. | Is it possible to fetch the private key of an SSL certificate using java |
If you know thethumbprintof the certificate, you can use theTest-Pathcmdlet to check whether the certificate is installed.Note: I renamed your function toTest-CertificateIsInstalledsinceTestis anapproved verb:function Test-CertificateIsInstalled
{
Param
(
[string]$Thumbprint,
[string]$Location ... | I have the following script to install a PFX file:$cert = Get-ChildItem -Path .\secrets\certificates\ssl\certificate.pfx
while($true){
write-host "Enter Password" -foregroundcolor yellow
try{
$pass = read-host -AsSecureString
$cert | Import-PfxCertificate -CertStoreLocation Cert:\CurrentUser\My... | Is there a way to check if a PFX cert is currently imported without getting the password |
I ran my all process with--debugmode, like this:gradlew \
-Dsonar.host.url=$URL \
-Dsonar.pullrequest.key=$NUMBER \
-Dsonar.pullrequest.branch=branch_name \
-Dsonar.pullrequest.base=main \
-Dsonar.qualitygate.wait=true \
sonarqube --debug > output.txtIt's helpfull to obtain file as artifact in short mode:artifacts:
... | My goal is to send full JaCoCo report to SonarQube and analyze it through gitlab. My full command is like:gradlew \
-Dsonar.host.url=$URL \
-Dsonar.pullrequest.key=$NUMBER \
-Dsonar.pullrequest.branch=branch_name \
-Dsonar.pullrequest.base=main \
-Dsonar.qualitygate.wait=true \
sonarqubeWhen I'm using my local command ... | SonarQube no new lines on merge request in Android gitlab project |
You most probably hit
https://issues.apache.org/jira/browse/CASSANDRA-9754
Having huge C* partitions or huge SStable count is not good in common case especially for scan requests
|
I'm trying to read all data of my table with spark to do a simple counting.
But some Cassandra nodes in my cluster throw java.lang.OutOfMemoryError. After this, my spark job stops because it cannot contact these specific nodes any more.
An easy solution would be to raise the amount of heap memory, but I think that it ... | Cassandra is OOMing when reading from spark |
1
+100
In order to load custom tiles in MKMapView you need to subclass MKTileOverlay and override method
url(forTilePath path: MKTileOverlayPath) -> URL
MKTitleOverlay contains x, y and z properties for the tile.
So the implementation ma... |
I have found a way to cache tiles with MapKit, but I haven't found any solution for loading all tiles inside an area to from the top level tiles to the bottom level tiles.
I want to cache all tiles for a rectangle area in my mapview. Is there any way to do this in Mapkit?
| Load all tiles for area in mapView |
I have created similar setup in my project, as we needed to set the exclusions from the maven command (same as you), and not via the sonar gui (Sonar documentation only refers to exclusions via sonar's gui) Here's what we did in our project:"-Dcommon.sonar.issue.ignore.multicriteria=e1,e2 " +
"-Dcommon.sonar.issue.igno... | Is it supported by sonar-maven-plugin to set the "Ignore Issues on Multiple Criteria" toNarrow the focusas-Dsonar.issue.ignore.multicriteriafor the sonar-maven-plugin run command?Any working example is welcomed. | SonarQube define "Ignore Issues on Multiple Criteria" in maven build |
Assuming the image uses a Java CMD, include the standard debug JVM arguments (What are Java command line options to set to allow JVM to be remotely debugged?), then expose the debug port when running a container, and in IDE set up a remote debug session on that port once the container starts up. | I have experience using Docker to develop a relatively complex application. It is very easy to debug an app using Visual Studio (2019). I just set docker-compose.yaml as the startup app and start debugging.Is it possible to debug an application that is published to Kubernetes locally using Docker Desktop? By debug I ... | What is the best way to debug an app deployed to Kubernetes locally using Docker Desktop? |
I was able to solve this problem. The issue was I skimmed the documentation and didn't see I had to request the repo scope during authorization to be able to modify stars :) Simply adding the "repo" scope fixed my issue!GitHub briefly mentions their scopes here:http://developer.github.com/v3/oauth/but no where was it m... | I'm currently attempting to check and see if a repo is starred by anauthenticated userusing the GitHub API (v3). I can successfully list the repos starred by the logged in user, but I can't seem to get it to work when checking if a repo is starred by the user.For instance..(GET) /user/starred?access_token=... correctly... | Checking if a repo is starred with GitHub API |
The type of certificate is exactly the same type of certificate as you would get for securing a website, yes. However, the domain name must be a valid internet domain (not .local)There is a good walk-through here forUsing Let's Encrtypt for Active Directory Domain Controller Certificates, including all the caveats you ... | I'm looking at hardening LDAP on my domain controller (DC). To do this I need to import a security certificate to the DC.I don't want to self sign as I've been told it is not best practice and the service I wish to integrate with LDAPS (Mimecast) does not recommend self signing.I've created my certificate request, bas... | Implementing LDAPS: Can I buy the same kind of SSL certificate as I would use to secure a web domain? |
If you are using Docker CE on Windows with Linux containers, specify double-quotes around the environment variables so that they are recognized:
docker run -e "ACCEPT_EULA=Y" -e 'SA_PASSWORD=MyStr@ngPassw0rd" -e "MSSQL_PID=Express" -p 1433:1433 -d microsoft/mssql-server-linux:latest
You will then be able to connect u... |
I've created a docker container using the following command:
docker run -e 'ACCEPT_EULA=Y' -e 'SA_PASSWORD=MyStr@ngPassw0rd' -e 'MSSQL_PID=Express' -p 1433:1433 -d microsoft/mssql-server-linux:latest
I'd like to use SSMS to connect to this database from my host machine.
Which parameters should I use in the SSMS login... | How to connect to a SQL Server database inside a docker container? |
Check
nvcc -V
and
nvidia-smi
and see if it shows our gpu or not.
Assuming your cuda cudnn and everything checks out,
you may just need to
1. Uninstall keras
2. Uninstall tensorflow
3. uninstall tensorflow-gpu
4. Install only tensorflow-gpu pip install tensorflow-gpu==1.5.0
5. Install Keras now.
I followed the... |
I'm trying to train a Keras model on the GPU, with Tensorflow as backend.
I have set everything up according to https://www.tensorflow.org/install/install_windows. This is my setup:
I'm working in a Jupyter notebook in a virtualenv environment.
The current virtualenv environment has tensorflow-gpu installed.
I have C... | Keras does not use GPU - how to troubleshoot? |
A helm chart and a container image aren't equivalent things to compare in KubernetesA container image is the basic building block of what kubernetes runs. An image will always be required to run an application on kubernetes, no matter how it is deployed.Helm is a packaging and deployment tool. It makes management of de... | I need to deploy NGINX to a Kubernetes cluster, for which I can either use a Helm chart or a Docker image. But I am not clear of the benefits of using a Helm chart. I guess my question is not specific to NGINX but in general. | What are the advantages of deploying with Helm chart over Docker image to a Kubernetes cluster? |
You can try creating any object likenamespaceor so and try checking the YAML output using the command you will get an idea if SSA is enabled or not.Command:kubectl create ns test-ssaGet the created namespacekubectl get ns test-ssa -o yamlIf there ismanagedFieldsexisting in output SSA is working.Server-side-applyi think... | Thepageon server-side apply in the Kubernetes docs suggests that it can be enabled or disabled (e.g., the docs say, "If you have Server Side Apply enabled ...").I have a GKE cluster and I would like to check if server-side apply is enabled. How can I do this? | How can I tell if server-side apply is enabled in my Kubernetes cluster? |
1
A docker image can have its own volumes that are not defined at container creation (for instance, with the -v parameter of docker run), but when the image it built. That's what the VOLUME statement in a Dockerfile is for.
See also the relevant section of the documentation... |
I am looking at this answer https://stackoverflow.com/a/32916890/271388 and I don't fully understand what's going on there.
If I understand it right, in docker volume is a mapping from host filesystem into container's filesystem. And docker's --volumes-from flag as well as docker-compose's volumes_from directive in do... | What does volume_from do if there are no volumes in the volume container? |
i've finally got it to work ! the key was to set network_mode to host :
https://docs.docker.com/compose/compose-file/
docker-compose.yml :
version: '2'
services:
web:
build: php5
ports:
- "80:80"
#links:
# - db:db
network_mode: "host"
db:
image: m... |
I'm a bit confused using Xdebug, Docker for Windows, and PhpStorm...
I have Xdebug configured in a container with PHP. Here is what appears in my php.ini from within this container :
xdebug.remote_enable=on
xdebug.remote_autostart=off
xdebug.idekey=PHPSTORM
xdebug.remote_port=9000
xdebug.remote_host=10.0.75.1
# xdebug... | How to setup xdebug and PhpStorm with docker for Windows (beta) |
I solved the problem.It is related to Keras & Tensorflow Memory allocation problem.
My setting automatically allocated all memory in GPU.
I solve it by the below.
Anyway, Thanks allimport tensorflow as tf
gpu_options = tf.GPUOptions(per_process_gpu_memory_fraction=0.2)
sess = tf.Session(config=tf.ConfigProto(gpu_option... | I am using EC2 GPU machine with pre-made AMIs.
I just put 'import keras' and run it.
It takes 11519MiB ( out of 12181MiB).
It's non-sense right?I did googling it. I guess it might come from the path setting.
I don't know which causes memory leak.Anyone who know the solution or experience similar with me??--UPDATE--
It ... | Only 'Import keras' takes 10GB in GPU |
After discussion, if the change of the tex file is only in term of metadata (and not actual file content change, after a latex recompilation), the GitHub Desktop might be unable to display any change.
Since it detects no change even though the git status list this file, it falls back to a "this file is empty" message.... |
The file naaclhlt2016.tex is not empty on the client or in the repository, however GitHub Desktop displays "This file is empty". What could explain this?
The file naaclhlt2016.tex is present on GitHub repository:
git status:
It creates conflict when I try to sync:
| GitHub Desktop: "This file is empty" |
The sidecar pattern is preferred because it is the easiest and more secure option. Traffic to the Cloud SQL Auth proxy is not encrypted or authenticated, and relies on the user to restrict access to the proxy (typically be running local host).When you run the Cloud SQL proxy, you are essentially saying "I am user X and... | Does anyone know the pros and cons for installing the CloudSQL-Proxy (that allows us to connect securely to CloudSQL) on a Kubernetes cluster as a service as opposed to making it a sidecar against the application container?I know that it is mostly used as a sidecar. I have used it as both (in non-production environment... | CloudSQL Proxy on GKE : Service vs Sidecar |
Execute the followings steps:DownloadSonarQube 6.4(this is the newest version)Place the zip in C:\SonarBefore unzipping right-click the zip-file and open the properties. Check the "Unblock" option (this is essential!).Unzip the zip-file in C:\Sonar, you can remove this zip file afterwards.Check that bin\windows-x86-x64... | I am using Sonar to prepare review report of my project.But i am getting the below exception while installing the server..Could anyone please help me any help will be highly appreciable.I referred the below link to start my installationhttps://docs.sonarqube.org/display/SONAR/Get+Started+in+Two+Minutes | How to start sonarqube5.6.6 server |
RewriteCond %{HTTP_HOST} ^domain.com$
RewriteRule ^(.*) http://www.domain.com/$1 [QSA,L,R=301]It should work, if it dosn't it comes from your DNS, or Vhost configuration. | Ok so I've rewrited URL in my website, now for some reason, it is throwing 404 error if I type www.domain.com, if I type domian.com, everything works fine.DirectoryIndex home.php
IndexIgnore *
#RewriteCond %{HTTP_HOST} ^www\.(.+)$ [NC]
#RewriteRule ^(.*)$ http://%1/directory/$1 [L,R=301]
RewriteRule ^home/?$ home.p... | Rewrite URL www.domain.com causing 404 on my page |
From the top of my head I'd blame a change inmatrixStats[ but see below and it appears blameless ] -- I am somewhat familiar with all the other moving parts and not aware of changes or bugs.One thing that is fishy though is the trailing line break:RUN install.r Rcpp RcppEigen matrixStats \You may try without it.Edit:A... | On its last line,thisDocker file callslittler::install.rto installRcppRcppEigenandmatrixStats.The whole code was working like a charm a couple of months back. Now, it bombs at that last step. More precisely,RcppandRcppEigenstill install perfectly, but when it comes to installingmatrixStats, I get:installing to /usr/loc... | checkCompilerOptions Error while installing package (littler/Docker) |
If you want to secure sub-domain and its sub-directories, you can get multi domain SSL certificate.Multi domain SSL Certificate will protect domain in following scenarios:example.com*.example.com*.abc.example.com*.example.net*.abc.com.auYou can secure up to 100 domains with this certificate.ShareFollowansweredJun 19, 2... | I have developed Facebook canvas app and for canvas App HTTPS and SSL certificate is required. I am planning to purchase SSL certificate but i don't know requirement of Facebook canvas app SSL certificate.My app may be hosted on subdomain or subdomain sub-directory. Please guide me which certificate is better for me. | SSL certificate requirement for Facebook Canvas App development |
While thealloc-retaincalls balance out inviewDidLoadandviewDidUnloadand should prove no problem memory-wise, it would be cleaner to take ownership only once and relinquishing it once rather than twice.- (void)viewDidLoad
{
[super viewDidLoad];
if (self.data == nil)
self.data = [NSMutableArray array];
}... | i'm a little bit confused with memory management in view controllers.Lets say i have header file like this:@interface MyController : UIViewController {
NSMutableArray *data;
}
@property (nonatomic, retain) NSMutableArray *data;
@endand .m file looks like that:@implementation MyController
@synthesize data;
- (void... | View controller / memory management |
try it on your local machine by its IP address, if it's not with the keycloak. if it's working try to disable your antivirus. if you can post the error also with deployment information.ShareFollowansweredJun 6, 2023 at 13:23yohannes getuyohannes getu3144 bronze badgesAdd a comment| | I have a micro-service based project using Keycloak, Spring Boot apps and others...
The project works perfectly on localhost. And now I want to test it on other devices like my phone on the same local network.I know my PC's IP Address (it's reserved on the router so it does not change).But somehow I can't access it.Fir... | How to run Spring Boot and Keycloak on local network |
There's no difference between the storage of the image and the base filesystem of the container, the layered FS accesses the images layers directly as a RO layer, with the container using a RW layer above to catch any changes. Therefore your goal of having the container running in memory while the Docker installation r... | I have a docker container which does alot of read/write to disk. I would like to test out what happens when my entire docker filesystem is in memory. I have seen some answers here that say it will not be a real performance improvement, but this is for testing.The ideal solution I would like to test is sharing the commo... | Docker: in memory file system |
For the first error, change
exec($command,$output=array(),$worked);
to
$output = array();
exec($command,$output,$worked);
Since the second parameter to exec() is a reference parameter, it has to be a variable, not an expression.
See Suppress warning messages using mysql from within Terminal, but password written in ... |
I am able to run the script from the browser and backs up my mysql database, but when I try to do it with a cron job, I am getting the error:
Strict Standards: Only variables should be passed by reference in
/main_dir/sub_dir/backup.php Warning: Using a password on the command
line interface can be insecure.
An... | Strict Standards: Only variables should be passed by reference in /main_dir/sub_dir/backup.php |
Non static properties (alias fields, alias member variables) have their own copy for each object instance of a class.
Methods, whether static or not, only exist in one copy for each class.
That makes sense, if you think about it: there's no reason to copy a behaviuor that doesn't change. Only the status (variables) ... |
My question is about memory use and objects in actionscript 2. If I have a class definition:
class test1{
public function one(){trace("Hello");}
public function two(){trace("World");}
}
And a second class definition:
class test2{
static public function one(){trace("Hello");}
static public function ... | AS2: Are functions declared in a class stored as separate instances taking up more memory on each object instantiated? |
If you want to keep the readme file you can pull and rebase it
git pull --rebase origin master
Then push your code back
git push origin master
If you don't want the readme file just push it forcefully
git push origin master -f
|
I'm stuck in this code. After git fetch I met a wall and don't know what a next step should I make to get all my commited files to GitHub server - now there is only one file README.md that was automatically created when saving a new repository. Thanks for help.
Freeware Sys@DESKTOP-VK97GA5 MINGW64 ~/Desktop/Coding Sta... | GitBash | origin master - rejected (fetch first) | no file in GitHub repository |
You cannot ignore a file once its been committed. You need to usegit rmto remove the files from the repo and then re-commit with them added to the git ignore file.Eg. I could remove all .htaccess files like:git rm -r .htaccessAlso see Git Ignore docs | How to add.gitignorefile after already push my project? I'm a git starter. Recently I pushed my Intellij Project to github, then I want to add.gitignorefile to shrink my project. | gitignore file not work after push? |
I think I actually figured out the answer to this. What you can do is to create an interceptor. Since all requests with ng-include actually goes through the generic $httpProvider you could intercept the request and add the cache buster.app.factory( "cacheBusterFactory", [ "VERSION", function( VERSION ) {
return {
... | I want to change the url each time ang-includedirective requests a partial. So far I'm able to see the url and the event like this:app.run(function ($rootScope) {
$rootScope.$on('$includeContentRequested', function (event, url) {
console.log(event);
console.log(url);
});
});Now I need to be able... | Change source url on $includeContentRequested |
docker is sometimes described as "light weight" in comparison to virtual machines because it:does not boot a separate OS per VM and is therefore faster to start/stopIn most scenarios requires less disk space due to sharing of common layers across imagesAgain due to the image layering, incremental deployments of new app... | I was reading about docker . I have understood that the platform helps in removing dependencies between different software life cycles by combining the dependencies and the software together.In the website of docker it was written that it is light weight , I didn't get that point as how it can be light weight when it h... | How is Docker light weight |
Have you tried addingtimer.join()? You'll need to join the Timer thread because otherwise the Lambda environment will kill off the thread when the parent thread finishes.This code in a Lambda function:import threading
import time
def this_will_await(arg,arg2):
print("Hello User")
print(arg,arg2)
def this_should_... | I am trying to implement Multithreading in AWS lambda. This is a Sample code that defines the format of my original code which I am trying to execute in lambda.import threading
import time
def this_will_await(arg,arg2):
print("Hello User")
print(arg,arg2)
def this_should_start_then_wait():
print("This starts")
... | MultiThreading in AWS lambda using Python3 |
From the docs:https://docs.aws.amazon.com/eks/latest/userguide/network-load-balancing.htmlWhen you create a Kubernetes Service of type LoadBalancer, the AWS cloud provider load balancer controller creates AWS Classic Load Balancers by default, but can also create AWS Network Load Balancers.ALB is not supported as a k8s... | I want to deploy Application Load Balancer for Traefik running in Kubernetes. So, I tried the following:kind: Service
apiVersion: v1
metadata:
name: traefik-application-elb
namespace: kube-system
annotations:
service.beta.kubernetes.io/aws-load-balancer-backend-protocol: "tcp"
service.beta.kubernetes.io/a... | AWS ALB service in Kubernetes |
Usejava.net.URIinstead of URL. | Theequals()method of the URL class in the Java class library makes a DNS request to get the IP for the hostname, to check the two IP's for equality. This happens even for URLs that are created from the sameString. Is there a way to avoid this internet access? | How to avoid, that URL.equals needs access to the internet in Java? |
1
You should be able to use Nginx map to detect the header value to create a switch.
Then you should be able to use rewrite to route accordingly to the desired location block
map $http_my_header $intercept {
default "intercept_on";
me "intercept_off";
}
server {
liste... |
I got 2 clients that may send same HTTP request to Server through nginx proxy.
one is browser the other is my own program, the difference is request send from my own program have custom HEADER my-header=me
My goal is:
if any request leads to a http:500 response of the Server, I would like the browser to show an Error... | NGINX conditionally turn on/off proxy_intercept_errors |
Many proxy servers operate the same way as man-in-the-middle attackers. Lots of network security depends on these proxy servers and your proposal would make it more difficult to implement a common security practice. Also, the check does not protect users against the obvious attack of a forged URL whose "authenticity"... | Of course, I should be more diligent to ensure that the server name in my Apache HTTPD.conf file match the certificate. But the browser is clearly unhappy when the certificate doesn't match the HTTP response.One user was alerted that "Security certificate problems may indicate an attempt to fool you or intercept any d... | Apache SSL Configuration and Browsers <GRIPE> |
Well, I found an alternative solution for the same. I created the socket in localhost
Here is my uwsgi file
[uwsgi]
uid = www-data
gid = www-data
master = 1
workers = 2
plugins = python
socket = 127.0.0.1:3100
enable-threads = true
processes = 2
pythonpath = <>
wsgi-file = <>
chdir = <>
|
I want to create uWsgi socket in my project folder and not in /tmp/
Here's my uWSGI config
[uwsgi]
socket = /tmp/uwsgi.sock #I want this in any other folder
#say in /home/me/Desktop/myDjangoApp/
chmod-socket = 666
processes = 1
master = true
vhost = true
no-site = true
But whenever I restart uWSGI with the socket cre... | Create uWSGI Socket in other folder? |
I got a Spring Boot app to run in anopenjdk:11-jre-slimcontainer and was able to successfully debug it with the following configuration.First, set jvm args when running your container. You do this via entrypoint.sh
but I decided to override my container entrypoint in docker-compose. I also expose the debug port.ports: ... | I have a Java application (.tar) mounted to a container. Theentrypointof the container starts that application.Dockerfile(the backend folder is mounted into the image as a volume)FROM openjdk:11.0.7
ENTRYPOINT /backend/entrypoint.shentrypoint.shjava -agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=*:5005 ... | How to debug a Java application running inside a Docker container using VSCode's Java debugger |
0
Per the documentation, the description of "environmentVariables" reads "These environment variable values are passed to the process when it's launched in the container."
Note the "when", so these environment variables aren't available for the docker build.
You can still a... |
In docker i need to pass 2 arguments for restore my private nuget packages
docker build -t backend-template --build-arg ARTIFACTS_PAT=My-pat --build-arg ARTIFACTS_ENDPOINT=My-endpoint .
When i pass this arguments on DockerfileBuildArguments tag in api.csproj as environment variables the build not works
This is the ... | Visual Studio DockerfileBuildArguments with enviroment variables not works |
As you mentioned in your question:While creating the instance, I have made
sure, allow-HTTP && allow-HTTPS flag was enabled.Accordingly to the documentationCreating and starting a VM instancesectionCreating an instance from a public image:SelectAllow HTTP trafficorAllow HTTPS trafficto permit HTTP or HTTPS traffic to t... | Team, Need quick help! I have created and hosted service on Compute engine in GCP. This is on a Ubuntu server, While creating the instance, I have made sure, allow-HTTP && allow-HTTPS flag was enabled. but still, I'm not able to connect to the service from outside.I have exposed the service on port 4000 but the tcp:80 ... | Connecting to service hosted on Compute Engine not working - Site cannot be reached / I have added the http(s) tags |
1
Looks like a Mac locale issue.
Run defaults write org.R-project.R force.LANG en_US.UTF-8 in Terminal.
Source
Share
Improve this answer
Follow
answered Nov 25, 2018 at 19:12
RomanRoman
... |
I tired to run install_github("dkahle/ggmap"), but it seems like there is an error when I try to install the ggmap.
install.packages("devtools")
library(devtools)
install_github("dkahle/ggmap", ref = "tidyup")
Here is the error message I get in my console when running the install_github code.
Downloading GitHub rep... | I get an error when trying to install dkahle/ggmap |
The accepted answer above is INCORRECT. Cron's time limit in Drupal is hardcoded to 240 seconds. See thedrupal_cron_runfunction inincludes/common.inc, specifically these lines:drupal_set_time_limit(240);andif (!lock_acquire('cron', 240.0)) {(based on the source of Drupal 7.12)So, there is no way to change this globally... | Whats the maximum execution time of cron. is it possible to modify it if so any side effects. | drupal maximum execution time of cron |
Use this:
bluwy/substitute-string-action@v1Here is an example:jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: bluwy/substitute-string-action@v1
id: sub
with:
_input-text: 'Hello World!'
World: GitHubUrl to the action with the full docs:https://github.com/bluwy/substitute-str... | I have a static website that I am deploying with Github Actions. The website consists of 1 HTML file and several .yaml config files. There is a simple javascript function that loads all the .yaml files. However, currently the list of .yaml files is hardcoded. Is there anyway to either:Use Github Actions to update the j... | Github Actions - Updating an HTML File |
Git doesn't store directories that don't contain files; it doesn't support that. If you'd like the directory to be created, you have some options:Add a deployment script that creates it. This could be apost-checkoutorpost-receivehook, depending on how you get the code onto the server.Create some file in the directory... | I have a project checked out from GitHub and developing it in PyCharm. In summary, the application is a backend stack for a web application. There is an "uploads" folder where images uploaded from the frontend is saved. During development, data is saved into this folder. I've noticed that if I try to add the folder, it... | How do I commit a folder but not its contents in PyCharm? |
It is based on redhat, but at this point its taken its own path. While you can use redhat/centos repositories, you may from time to time, run into dependency conflicts. | I have an EC2 instance where I have bash & php 5.3 scripts running together (install / copy done by bash, web app via php of course), I need to port these files to a classic dedicated server.My goal is to choose the "closest OS" to the standard amazon EC2 linux distribution, you know to minimize the work done in order ... | Which unix flavor is the standard amazon EC2 linux image based on? |
A very simple yet good solution is to run a full backup using sqlcmd (formerly osql) locally, then copy the BAK file over the network to a NAS or other store. It's sub-optimal in terms of network/disk usage, but it's very safe because every backup is independent and given that the process is very simple it is also ver... |
I'm setting up a SQL Server 2008 server on a production server, which way is the best to backup this data? Should I use replication and then backup that server? Should I just use a simple command-line script and export the data? Which replication method should i use?
The server is going to be pretty loaded so I need a... | SQL Server 2008 - Best Backup solution |
These are the three approaches I'd be thinking of:1) Maybe SQL Server performance will be good enough that you don't need to cache. You might be underestimating how well SQL Server can do its job. If you do your joins right, it's just one query to get all the counts of all the users that are in that thread. If yo... | I would like to develop a Forum from scratch, with special needs and customization.I would like to prepare my forum for intensive usage and wondering how to cache things like User posts count and User replies count.Having only three tables, tblForum, tblForumTopics, tblForumReplies, what is the best approach of cache t... | Best approach to cache Counts from SQL tables? |
The Prometheus endpoint is provided by the Spring Actuators. Those are endpoints that are automatically created. I don't believe there is any support for the Play Framework and those actuators.You could useplay prometheus filtersto create the play equivalent endpoint. You'll want to ensure theCollectorRegistryis the sa... | I am new to prometheus + spring. My application runs on play + spring. In order to use micrometer for monitoring, I added :"org.springframework.boot" % "spring-boot-starter-actuator" % "2.2.4.RELEASE","io.micrometer" % "micrometer-registry-prometheus" % "1.2.0"andmanagement.endpoints.web.exposure.include="prometheus"in... | integrating prometheus with play + spring application |
Your setting time is beyond reach.Spring Quartz never execute the task which time is beyond reach.So change your setting time. | I am getting the "Based on configured schedule, the given trigger will never fire" error when scheduling my job. I have tried adding ".startNow()" to the trigger, but that didn't solve it. I don't understand what I have done wrong.JobDetail jobDetail = newJob(DeploymentJob.class)
.withIdentity(scheduleName)
... | Quartz: Based on configured schedule, the given trigger will never fire |
I don't know why do you want to do that, seems to me like it's not a good idea. But if you really need this, the simpliest way to do that is to use symbolic links.ln -s /var/www/html/example/application/themes/ /var/www/html/example/public/themes/ | I have a Laravel application in a directory:/var/www/html/example/The public folder of the site is:/var/www/html/example/public/I have a folder outer public folder with images, css/js and other files:/var/www/html/example/application/themes/I want to serve these files from this folder as follows:http://www.example.com/... | Laravel application: serve static files from outer public directory |
when configuring Grafana to use HTTPs you need to specify cert & key paths, looks likely that Grafana could not find one of them. | I'm trying to install Grafana on a server, and installation goes through properly. However, when I try to start the service (usingsudo service grafana start) it fails with the cryptic message:2016/02/11 18:45:38 [web.go:93 StartServer()] [E] Fail to start server: open : no such file or directoryI have been unable to fi... | Grafana fails to start server |
If you really want to go without garbage collection, you need to use the --gc with the none parameter, as explained in the Nim Compiler User Guide. The none parameter disables the garbage collector, leaving you on your own. This usually means any string operations will produce a warning, because despite memory being a... |
I would like to use Nim in a soft-realtime context, where both memory allocation and garbage collection exhibit too much latency. Therefore, manual memory management is desirable- or, even better, working exclusively from stack memory.
Which subset of Nim can I work from in order to achieve stack only memory allocatio... | How to develop on the stack with Nim? |
Option 1: at container start
You can use a wrapper script to create your environment variables with the inheritance that you wish. Here is a simple wrapper script
wrapper.sh
#!/bin/bash
# prep your environement variables
export command="echo Hello $var_env"
# run your actual command
echo "Hello $command"
Your docke... |
I am learning Docker and facing issue in substituting the value of one env variable into another env variable.
This is my Dockerfile
FROM ubuntu
ENV var_env=Tarun
ENV command="echo Hello $var_env"
CMD ["sh","-c","echo Hello $var_env"]
Now, after building it with tag name "exp", then
sudo docker run -e "var_env=N... | Dockerfile ENV variable substitution into another ENV variable |
In the OutputCache set theVaryByCustom="Language"and update you Global.asax file to override the HttpApplication.GetVaryByCustomString Method by adding the following code:public override string GetVaryByCustomString(HttpContext context, string custom)
{
if (custom.Equals("Language"))
{
r... | I would like to use page level caching on my asp.net page. vary by param works fine - however, the page content is cached in the language of the original request. If the same url / param is requested and the user is viewing in a different locale than the first request (French instead of English for example) - the cac... | is it possible to use asp.net page level caching with vary by param and localization |
This can be done using the AWS Eventbridge Rule. Create a rule with the following pattern:{
"source": [
"aws.redshift-data"
],
"detail-type": [
"Redshift Data Statement Status Change"
],
"detail": {
"state": [
"FAILED",
"FINISHED"
]
} }This rule will be triggered whenever a scheduled query fails or completes successful... | I am able to successfully schedule a redshift query, which is not very fancy. Just simple truncate and load. I also created a SNS topic and attached to this query. I am getting an email notification when this query runs.
My question is - Is it possible to customize this email notification with custom body? For eg - In ... | Success and Failure notification for Redshift scheduled query |
I tried to resize the machine type for my Windows server based on Google's recommendation, resizing was done successfully without changing the external IP address since my VM was using a static IP. Instance IP address changes if using an Ephemeral IP.At this point, I would verify if DNS A record is pointing to my curre... | I have a wordpress site which I created using Google Cloud Launcher. From what I can tell, this process created a VM and installed debian 8 with apache, php, and wordpress.My site was running fine and I set up a custom domain. Then, Google suggested my instance was not large enough and I needed to resize the VM. They h... | Google Cloud Launcher Wordpress Site Times Out After VM Resize |
That would not be a feature directly available in GitHub Desktop.You might consider a hook, for at least the push automation side,as in here.Some editors,like VS Code, can automatically and periodically fetch refs from your remotes. But if GitHub Desktop has no such capability, you would need tosetup some cron task.Sha... | Automatic Push/Pull in Github DesktopWhen working on Code in Visual Studio Git hub Desktop is my absolute favorite tool to use. It makes collaboration between me and my fellow programmers or even between my own laptops seamless, or almost anyway; It is really helpful being able to see the changes but it has one major p... | is there any way to make github desktop pull and push changes automaticcally |
Could you please try following. Considering that you don't want to allow any IP starting from112then we can keep it simple regex. We need NOT to mention any other digits here since you are not concerned about it.RewriteEngine on
RewriteCond %{REQUEST_URI} ^(.*)?wp-login\.php(.*)$ [OR]
RewriteCond %{REQUEST_URI} ^(.*)?w... | I thought my syntax below would work great to allow IP Ranges using an asterix as the wildcard, but no joy...Any idea what would work here?My IP changes the last two batches of numbers....<IfModule mod_rewrite.c>
RewriteEngine on
RewriteCond %{REQUEST_URI} ^(.*)?wp-login\.php(.*)$ [OR]
RewriteCond %{REQUEST_URI} ^(.*)?... | Adding a wildcard IP range to htaccess file? |
Try:firewall-cmd --zone=public --add-port=80/tcp --permanentWorked for me on CentOS Linux release 7.1.1503 (Core) | I am using Centos 7, and trying to open ports 80 and 443.Following instructions fromcentos 7 - open firewall port,RHEL7: How to get started with Firewalld,How to open http port 80 on Redhat 7 Linux using firewall-cmdand some others, I've got the following:[ricardo@m42srv02 ~]$ firewall-cmd --list-all
public (default,... | Port 80 closed in Centos 7 with firewalld service |
As for googlelogin, you should disconnect the google api client inonStop()method of the activity.mGoogleApiClient.disconnect();So that it is disconnected even if the activity is in the backstack.
The onDestroy() is not reliable. Although it is advisable that you loose the reference to the object in theonDestroy()method... | Startscreen of my project is having options for login with facebook and google. so i have initialised both the sdk's there. When I checked with leakcanary ,there is a lot of memory leaks in the startscreen which in fact is due to these sdks.. how to catch these memory leaks? | Is there any way to de-initialize the googleapiclient, facebook login sdk, etc in the onDestroy of my activity? |
Unfortunately, EclipseLink doesn't have a feature which covers auditing out-of-the-box.We use aSessionEventListenerto intercept a flush or commit and use the calculated changeset for inserting the auditing data into audit tables. | I have been looking at Hibernate Envers for entity auditing. I'm using EclipseLink but I'd like something similar.I've seen some implementations that involve creating a SessionCustomizer to handle some of the persistence of auditing data. I'd really like something like Hibernate where I can simply annotate the entity... | Hibernate Envers for EclipseLink (Entity Auditing) |
Once your files are checked into source control, provided you have added everything that isn't a temporary or build file it should be safe to delete the code.Since I've started pushing more and more local files to GitHub (and deploying them via GitHub Pages), my computer is running out of storage and is found to be slo... | Coding newbie here.This might seem like an odd question, but I am wondering what the usual convention is for developers when they find their computers running out of storage space.Since I've started pushing more and more local files to GitHub (and deploying them via GitHub Pages), my computer is running out of storage ... | Computer storage issue - Is it okay to delete local files after pushing and deploying on GitHub? |
I would suggestcreating an architectural constraintwithin Sonar.The example demonstrates a rule banning the use of *java.sql.** classes.ShareFolloweditedSep 5, 2017 at 9:05bigbear300154699 silver badges2020 bronze badgesansweredJan 17, 2012 at 0:23Mark O'ConnorMark O'Connor76.6k1010 gold badges140140 silver badges18618... | Our team is looking to have better compliance with the OWASP guidelines, and one of the tasks is the prevention of SQL Injection attacks. In order to facilitate this, I was looking for a way to automatically check for the usage ofjava.sql.Statementin our codebase, so this could be flagged and changed to usePreparedSta... | Looking for a way to prevent to usage of java.sql.Statement in project |
I would solve it with an assembler block, do a full test for RAM blocks.Copy a block to a temp location, test the block and restore it.Obviously the interrupts has to be disabled, when the test executes.It's not necessary to test all blocks at once, to avoid long blocking times.Using assembler here to have the full con... | Working on a bear metal application in a Nios II embedded processor. A requirement of the product is that it does a full range memory test of the SRAM which the application code uses once up and running.How can I do this? Clearly, I can't blindly just setup a pointer before main() and start writing / reading test patte... | How can you do a full range memory test on an SRAM test on the SRAM your application is using? |
Compose will expand variables from the environment where you are running compose. To expand the variable inside your container, escape the $ using $$:
command: '/bin/sh -c "echo $$DEBUG"'
For more details, see: https://docs.docker.com/compose/compose-file/#variable-substitution
Edit: I've also added a shell inside th... |
I want to print environment variable defined in docker-compose file.
Here is my docker-compose-1.yml:
version: '3.6'
services:
busybox:
image: busybox
command: 'echo $DEBUG'
environment:
- DEBUG='123456'
And, try to print the DEBUG environment variable in docker container:
☁ environment-variable... | docker-compose, can't print environment variable in docker container |
You need to containerize it before deploy to SageMaker.This might be a good start:https://aws.amazon.com/blogs/machine-learning/train-and-host-scikit-learn-models-in-amazon-sagemaker-by-building-a-scikit-docker-container/ShareFollowansweredOct 23, 2018 at 19:12JohnaJohna10122 bronze badgesAdd a comment| | I have already developed a scikit learn based machine learning model and have it in a pickle file. I am trying to deploy it only for inferencing and found sagemaker on aws. I do not see scikit learn based libraries on their available libraries and I also do not want to train the model all over again. Is it possible to ... | Can i deploy pretrained sklearn model (pickle in s3) on sagemaker? |
1
As System Architect I think it is better to have a single unified API domain where we do HTTP (layer 7) routing to reach our endpoints. You can make your system more flexible without any changes for your clients. For example you have a microservice with routes:
api.todos... |
Our application is based on an API first architecture and is currently based on a single domain / service:
api.todos.com
Consumers of the API are :
Our web-frontend
Our mobile-apps
Other business / public
We will be building new micro-services written in different languages for the same application. For example we m... | API design - splitting into different sub-domains (micro-services) |
This gist helped me solved this problem(before that, talked to AI for a while, chaos info provided, wasting time), hope it can help you as well(which should):https://gist.github.com/yermulnik/017837c01879ed3c7489cc7cf749ae47Let me summarize what I did:Get tokens for two(or more) github accounts, visit:https://github.co... | I'm struggling with git/SSH multiple identities (one personal/work and one dedicated to yet another company)I've managed to somehow create a virtual local "routing" thanks tohttps://simonbasle.github.io/2017/10/git-identities-and-ssh/, which selects the right SSH key depending on where the local repo is located on the ... | How to run "gh repo create" with a specific user/SSH key? |
1
I solved my problem with the following command:
docker exec -it <name of container> php artisan migrate
In this case, I used my main container's name and it worked. I kept DB_HOST as "db" as I think it should be.
I can reach my database from PHPMyAdmin. I added it to d... |
I don't know the technical terms of the LAMP stack very well so I will try to explain myself as much as I can. I have my project in my local Ubuntu (running on Windows 10 pro). I ran docker from WSL and I edited the default Laravel Sail docker-compose file.
my env file is like this:
DB_CONNECTION=mysql
DB_HOST=db
DB_P... | Laravel env configuration on Docker using MySQL |
well to use the code you'll have to download it in a way or another, so you may implement some python frontend that would allow to download files "on demand" (and probably cache them), but in the end its always about downloading. Nevertheless you can probably avoid downloading the git "history" which might be huge. I ... |
I cannot find any straightforward answer as to if this is possible or not. Lets say I have a python application that I am versioning. Lets also say that I have some custom modules I have written that the application uses. Is it possible for me to reference the python modules that are on my gitlab server from my local ... | Referencing code libraries stored in git without downloading them? |
2
To remove server side pre-rendering erase asp-prerender-module in Index.cshtml see here for the exact line details. Hot module replacement will continue to function. As for performance you'll see no noticeable changes with the amount of traffic your proposing. There are a... |
I have created a GitHub repo that currently has two branches, master, and clean_state (The default Angular 2 SpaTemplate). I am looking to remove the server-side rendering while still keeping the application working in a similar way. I am working with Visual Studio 2017 Enterprise edition and this project is an Asp.Ne... | Angular 2 SpaTemplate how to remove server-side rendering and what does that mean performance wise |
this works for me:$(kubectl exec <pod-name> [-c <container-name>] -it -- cat <file-path>) > <local-file> | Say I have, my-namespace -> my-pod -> my-container
and I have a file located at my-container:/opt/tomcat/logs/catalina.2017-05-02.log. I have applied the below command to copy the file which isn't working,kubectl cp my-namepace/my-pod:/opt/tomcat/logs/catalina.2017-05-02.log -c my-container .Note: I have the tar binary... | How to copy file from container in a pod in a specific namespace? |
There is no such concept of functionality.The best you can hope for is for said functionality to be mentioned in theREADMEof the project, or its description.See "Search by repository name, description, or contents of theREADMEfile", and its qualifiersin:readmeandin:description.For instance:https://github.com/search?q=j... | I am looking for interesting GitHub projects to work on, for example, I am interested in photography and timelapse videos, and I am looking for mac or windows desktop open source apps that will allow me to make time lapse clips.There doesn't seem to be an advanced feature on GitHub that allows you to search by project ... | How to search for github projects by their functionality? |
From bull quick guide:The process functioncan also be run1in a separate process. This has
several advantages:The process is sandboxed so if it crashes it does not affect the
worker.You can run blocking code without affecting the queue (jobs
will not stall).Much better utilization of multi-core CPUs.Less connectio... | I have been using Bull for background tasks in my node application.https://github.com/OptimalBits/bullNow that node is single threaded by nature. Does bull use the same thread on which node application is running or it forks another thread and runs as a separate instance? | NodeJs Bull for Background tasks |
That should mean the remote tracking upstream branches are already up-to-date.You can check that with:git branch -avvThat will displayallthe branches, including the remote tracking one, with their associated SHA1.As mentioned in the comments, even if the remote tracking branch are not up-to-date and were actually fetch... | I have Git setup to have access to twogithubrepositories: the upstream remote that I don't have collaborator (write) access to, and the fork I created of that which I do have write access to. Below is what I get when I rungit remote -v.origin https://github.com/samholmes1337/secret-society (fetch)
origin https://git... | Git isn't fetching upstream data? |
It's because of padding (kind of like rounding).
for example:
struct example1
{
char a;
int b;
char c;
}
struct example2
{
char a;
char b;
int c;
}
will likely differ in size, first will have size of 12B, second will likely only eat 8B (arch and compiler dependant).
Edit: gcc does padding by ... |
#include <stdio.h>
typedef struct {
short x,y;
char type;
} Tile;
int main(int argc, const char *argv[])
{
printf("%d\n",sizeof(short));
printf("%d\n",sizeof(char));
printf("%d\n",sizeof(Tile));
return 0;
}
The output is:
2
1
6
I expected sizeof(Tile) to be 5, instead of 6. Is this a well-de... | Why does this struct definition add extra one byte of memory usage? |
Apparently i figured out the problem. Using a json file to set the credentials still led to the error. Using only the config object without the flag -inMemory caused an error too. The combination of hard coding the credentials in the script and using the -inMemory flag while starting the dynamodb locally seemed to sol... |
im setting up a dynamodb locally to test with my Node app. To set it up i just plain out copied the code from here and adjusted it for my needs. This is the code:
var AWS = require("aws-sdk");
var config = ({
"apiVersion": "2012-08-10",
"accessKeyId": "abcde",
"secretAccessKey": "abcde",
"region": "us-west-2"... | "Could not load credentials from any providers" while using dynamodb locally in Node |
4
You must tell Git to squash all commits except your last commit to achieve what you expect of having to resolve conflicts only once.
To do this, initiate an interactive rebase on top of M4 while your feature branch is checked out:
git rebase -i M4
You'll be presented wit... |
I am new to git commands and recently came over the git rebase command. I got a doubt regarding why the git rebase command replays the commits of feature branch one by one instead of just replaying the latest commit on the feature branch.
This was my scenario on a project where I was working:
M1 --- M2 --- M3 --- M4
... | Why git rebase replay the feature branch commit one by one? |
3
It seems you don't have bundler installed.
Try running gem install bundler and then proceed to the app's directory and run bundle install
Does that help?
Share
Improve this answer
Follow
answer... |
Hi I forked an example of a Rails app that uses Devise. It was designed as an example of how to use Devise authorization. I also cloned it to my computer. However, when I went into the folder to start the server with rails s I got an error message
Could not find rails (>= 0) amongst [] (Gem::LoadError)
from /Lib... | Using a Rails project from GitHub -- server didn't start |
Thanks to @louahola for the improvement on my initial answer.
This will get you the Account ID for your key pair:
import boto3
sts = boto3.client(
"sts", aws_access_key_id=ACCESS_KEY, aws_secret_access_key=SECRET_KEY,
)
account_id = sts.get_caller_identity()["Account"]
If you are running on an EC2 instance with ... |
I have an AWS_ACCESS_KEY_ID and an AWS_SECRET_KEY. These are active credentials, so they belong to an active user, who belongs to an AWS Account. How, using Boto3, do I find the ID of this AWS Account?
| Get AWS Account ID from Boto |
This is a glitch in xCode. You will have to install git and repair/prepare the repository from the git command line or another git tool then reopen the project in xCode and then it will be recognized.xCode is great for git when it works but will break sometimes and need manual repair/tweaking of a repository outside of... | Open xcode then click "Connect to a repository"After entering the URL the button on the bottom changes to clone. FYI The repository is private and should require a github password and userid. Clone button is then clicked.It asks where to save the file. I choose a location then it comes here:Always trust github.com is c... | Clone repository from github in xcode userid password error |
Http Error 407is thrown when the resource you are trying to access needsProxy Authentication. But as you are accessing the service over127.0.0.1, which indicates it is your local system, you shouldn't get407error. Try adding the entry to your hosts file (UnderYOUR_WINDOWS_FOLDER\System32\drivers\etc) as127.0.0.1 ... | I am using sonar client API in order to display the code smells in a personalized version. But I am getting the above error while doing so? before I used to get the output.public class ab{
public static void main(String args[]) {
try {
String url = "http://127.0.0.1:9001";
String login = "admin";
String pas... | Sonar client org.sonar.wsclient.base.HttpException: Error 407 |
All versions of NUnit are supported on Mono. There is no install package but you can get all the binaries as a zip. | I'm currently running unit tests for a Xamarin application using the nunit-console (2.4.8) provided by the Mono Framework on OS X.I'm trying to publish the results through SonarQube and I believe for this to work I need NUnit 2.5 or higherCurrently SonarQube errors because of a missing "errors" attribute in the xml res... | Mono Framework NUnit Version |
I founded that HTML/CCS files stored in doc/ or docs/ folder at the root of your project will not impact repository language stats.
|
I made a small scraper in Crystal hosted on Github. I want to store website HTML for testing purposes but when I do my Github project appear as written in Html (because of quantity of HTML compared to quantity of Crystal lines).
How can I "ignore" theses Html files?
| Github - Store Html/CSS file without change langage stats |
If its in the local filesystem, the URL should be file://user/hadoop/wet0
If its in HDFS, that should be a valid path. Use the hadoop fs command to take a looke.g: hadoop fs -ls /home/hadoopone think to look at, you say it's in "/home/hadoop", but the path in the error is "/user/hadoop". Make sure you aren't using ~ in... | I'm trying to read in a text file on Amazon EMR using the python spark libraries. The file is in the home directory (/home/hadoop/wet0), but spark can't seem to find it.Line in question:lines = spark.read.text(sys.argv[1]).rdd.map(lambda r: r[0])Error:pyspark.sql.utils.AnalysisException: u'Path does not exist: hdfs://... | Spark/Hadoop can't find file on AWS EMR |
I'm not familiar with the prometheus functions; they look like they might be window functions - if so, that's not currently available in druid directly. | I wrote an application and deployed a Prometheus, that scrapes metrics from the app and stores it in Druid (I'm forced to use this database in production for metrics). Now I want to make a dashboard in Grafana to monitor the application. If the datasource is Prometheus, one query would look likesum(rate(http_request_du... | Druid sql functions analogue to Prometheus 'rate' and 'histogram_quantile' |
1
As far as I know, the Runtime memory methods only report about the HEAP as a total (so all the values are totals of old, eden, survivor and permanent). This is why your values would be off, as there isn't a jstat output telling you the overall heap utilization.
One thing... |
I am running a java application where i have observed below :
through code i am calculating memory utilization :
long freeMemory = Runtime.getRuntime().freeMemory();
this.memUsage = 100f - (freeMemory*100)/this.maxMemory;
where
instance.maxMemory = Runtime.getRuntime().maxMemory();
Timestamp S0 S1 E ... | Java Memory : jstat vs Runtime.getRuntime().freeMemory(); |
upstream: "https://:80/v1/some/page",It is not really clear to me what you are trying to achieve. But it is very unlikely that you have a HTTPS server on port 80. Port 80 is commonly used by HTTP not HTTPS. Trying to access it by HTTPS will usually result in a HTTP error response by the server which, when interpreted a... | I am trying to proxy requests to a remote server, this is how I configure my Nginxupstream myupstream {
server remote-hostname;
}...location ~ ^/(v1|v2|v3)/.*$ {
proxy_pass https://myupstream;
# also tried these options:
# proxy_ssl_server_name on;
# proxy_ssl_verify off;
# proxy_set_header Host... | Nginx upstream to https host - ssl3_get_record:wrong version number |
There are various alternative provided by mongoDB in order to backup Mongo data.1. Mongodump toolMongodump can be used to back up the live server data . This can be used to take backup of entire cluster /server /database/collection even while data base is up and running . This can be used if you have less data write ac... | Closed.This question does not meetStack Overflow guidelines. It is not currently accepting answers.This question does not appear to be abouta specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic onanother Stack Exchange site, ... | How to backup really huge mongoDB database [closed] |
Something like this should work:Options +FollowSymLinks -MultiViews
# Turn mod_rewrite on
RewriteEngine On
RewriteBase /
RewriteCond %{HTTP_USER_AGENT} ^.*(MSIE.*Windows\ NT|Lynx|Safari|Opera|Firefox|Konqueror) [NC]
RewriteRule ^$ about/ [L,R] | On a wordpress website, we're using wptouch pro plugin to provide a mobile version of the website (so no separate mobile website).
We get mobile traffic through a QR code pointing to our frontpage (e.g. www.example.net). However, we'd like desktop users to be redirected to www.example.net/about/ page.
Is it possible to... | .htaccess to redirect homepage to "about" page for desktop users |
This is possible but the trick is that you have to use system properties (usingsystemPropprefix):systemProp.sonar.host.url=http://localhost:9000
systemProp.sonar.jdbc.url=jdbc:postgresql://localhost/sonar
systemProp.sonar.jdbc.username=sonar
systemProp.sonar.jdbc.password=sonar
systemProp.sonar.login=admin
systemProp.s... | I want to Externalize the sonar configuration properties from build.gradle file to gradle.properties file.for example,
apply plugin: 'sonar-runner'sonarRunnersonarPropertiesproperty "sonar.java.coveragePlugin", "jacoco"
property "sonar.host.url", "http://10.42.58.229:9000/"
property "so... | Externalize the sonar configuration properties to gradle.properties file in user home |
+50You should useBranch Pluginin order to analyse branches for only new issues. This plugin has a corresponding Quality Gate:For short-lived branches, there is a kind of hard-coded quality gate focusing only on new issues.It will create Issues only if there are new bugs or vulnerabilities.As per the plugin documentatio... | I am currently introducing SonarQube into a large legacy project. This means that there are already hundreds of warnings, in the first step I would like to ensure that there areno new warningscoming from our feature branches.To achieve this, I want to have the Sonar analysis run on every feature branch, compare it to t... | SonarQube Leak Period between Branches or Projects |
First check wheather the post_at,day_open are edit in current date$date = date('Y-m-d');
$job= DB::table('job') ->select('post_at','day_open','block')->where('updated_at',$date) -first();
$id=$job->id;
if(isset($job) && !empty($job))
{
$finding=CronJobCotroller::pushNotify($id);
}if it's true i... | I have thejobtable containspost_at,day_open,blockpropertiesThepost_atproperty is the day when user post the job(Ex:2015-11-24)Theday_openproperty is the day that job is open(Ex:10)Theblockproperty can contain 2 values 0 or 1. Ifpost_at + day_open > right nowtheblockvalue will change from 0 to 1So how can I do that usin... | Cronjob in Laravel 5 |
It refers to the Kubernetes Horizontal Pod Autoscaler.https://kubernetes.io/docs/tasks/run-application/horizontal-pod-autoscale-walkthrough/Example:https://learn.microsoft.com/en-us/azure/aks/tutorial-kubernetes-scale?tabs=azure-cli | What does themaxReplicasproperty mean in the pipeline yaml in Azure in context of the k8s deployment?E.g. inthisdocumentation themaxReplicas: 10is mentioned. But there is no explanation about what it means. At least I was not able to find one. Would be grateful if someone will help me to find the documentation on that.... | What does the `maxReplicas` property mean in the pipeline yaml in Azure in context of the k8s deployment? |
Check exactly what key is used with:git -c core.sshCommand="ssh -Tv" pullThat way, you will see which URL and key is actually used by your command, and have some clue as to why the current key does not work.Note thatssh-addis only valid for your current session: signing out/back in would require anssh-addagain. Which i... | I want to connect with GitHub from my server Centos.I was doingssh-add ~/.ssh/id_rsaand these problem solved.But, I don't know why, when I am sign out and then sign in again, the problem shows again.Anybody know how to solve this problem? | How to avoid Permission denied (publickey) when pulling from github? |
|is a shell symbol which only works within a shell environment.CMD command param1 param2 (shell form)This will work as follows:CMD [ "sh", "-c", "command param1 param2"].CMD ["executable", "param1", "param2"] (exec form, this is the preferred form)This will not invoke a shell, so|will not function.You may reference som... | I am running through a Docker tutorial, and the Dockerfile contains the following line:CMD /usr/games/fortune -a | cowsayWhen usinghadolintto lint the file, I get this recommendation:DL3025 Use arguments JSON notation for CMD and ENTRYPOINT argumentsSo I update theCMDline with JSON notation for the arguments:CMD ["/usr... | Proper JSON notation syntax in a Dockerfile when piping output through multiple commands on a `CMD` line? |
0
It is possible to make cursors for ordered SELECT's in both databases, and go 'parallel' through cursors records (like in merge sort) and insert missing rows in database A. It is the best to first insert them in temporary table(s) not to confuse cursor and with that there... |
There're two sqlite databases A and B, both consist of 10+ million rows. The task is to read all records in B and add those new ones into A if they are not already existent there.
There're no duplicates in A, but there're plenty of duplicates in B.
I found this is a tricky job since back when both A and B only consi... | Fastest way to add new non-duplicated records into database A from database B(both are huge) |
Hey OP this is a tricky one, but Microsoft does have some documentation for it. The app gateway needs to be able to route to the internet and the backend cluster. (https://learn.microsoft.com/en-us/azure/architecture/example-scenario/gateway/firewall-application-gateway)
I use the following configuration:Route Table #1... | just a question, on microsoft pagehttps://learn.microsoft.com/en-us/azure/aks/configure-kubenet#bring-your-own-subnet-and-route-table-with-kubenetit says"With kubenet, a route table must exist on your cluster subnet(s). AKS supports bringing your own existing subnet and route table.
If your custom subnet does not conta... | AKS Kubenet bring your subnet, routetable, and AGIC AKS integration |
Do not rely onretainCountfor memory analysis. Go through the reference documents onMemory Managementfor further info | I'm still not that great with memory management techniques, and wondered if someone could explain this weird behaviour to me. Consider these 3 pieces of code which I have been testing:DofView* dofView = [[DofView alloc] initWithNibName:@"DofView" bundle:nil];
NSLog(@"dof retain count = %d", [dofView retainCount]);This ... | Memory management with pushViewController |
You need to escape the $ with $$
command: bash -c 'while [[ "$(curl --connect-timeout 2 -s -o /dev/null -w ''%{http_code}'' https://mock-server:4000/readiness)" != "200" ]]; do echo ..; sleep 5; done; echo backend is up; npm start'
command: bash -c 'while [[ "$$(curl --connect-timeout 2 -s -o /dev/null -w ''%{http_... |
In my docker compose I have the following command:
command: bash -c 'while [[ "$(curl --connect-timeout 2 -s -o /dev/null -w ''%{http_code}'' https://mock-server:4000/readiness)" != "200" ]]; do echo ..; sleep 5; done; echo backend is up; npm start'
which waits until mock-server is up then run the start command for b... | docker compose command: Invalid interpolation format for "command" option in service |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.