Response stringlengths 15 2k | Instruction stringlengths 37 2k | Prompt stringlengths 14 160 |
|---|---|---|
This should do the trick:RewriteEngine on
RewriteBase /
RewriteRule ^page/([^/]+)/? file.php?source=$1 | I'm working on a project and need some help with rewriting some URLS...We have a URL such ashttp://www.example.com/page/a-c/I need it to be interpreted by the server as:http://www.example.com/file.php?source=a-cMy .htaccess rewrite skills are not that great! | .htaccess rewrite rule to change a path to a query string |
Instead of
git rebase master
you can alter this to
git rebase -i master HEAD~n
where n is the number of commits on your branch.
You will then see something like this:
pick f7f3f6d Change my name a bit
pick 310154e Update README formatting and add blame
pick a5f4a0d Add cat-file
# Rebase 710f0f8..a5f4a0d onto 710f0f... |
Can someone help give me a a sequence of git commands to help squash any commits that I have in my pull request?
Let's assume that I have pushed changes (or just committed) and would like to squash past commits so it only shows as one.
Is this a reasonable chain of commands?
git checkout master
git pull origin master
... | Best way to squash commits using git rebase master |
I have used darkroom for my angular 2 project, darkroom gives an object that contains initialized canvas, from where you can get dataUrl. see below example:var _darkroom = new Darkroom('#target');
var b64Url = _darkroom.canvas.toDataURL(); | I finally found a Plugin (http://mattketmo.github.io/darkroomjs/) for Cropping and Rotating my images ;).
My question is how and where I have to implement the function "canvas.toDataURL();". On the Github site is only explained how to write the code not where to implement. | Javascript Cropping plugin: Darkroom |
Go intoSettings > Version Control > Gitand check the checkbox forExecute branch operations on all roots. According to the alt-text of this checkbox:If selected, you would be able to checkout, compare, delete and create new branches in all Git roots with a single action. It will also affect behaviour of the push dialog.... | I have 30 microservices opened in Intellij IDEA.
Is there any way I cancheckout all projects to master branch by 1 operation? | Checkout all projects to a certain branch |
2
I don't believe there is a way to do this right now. There is a long, running issue commentary on this topic.
One of the comments mentions that it will be available in version 3 of the schema.
I've tried a minimal version locally:
version: '2'
services:
a:
image: ... |
There is a setup with 1...N application containers which are connected to different backend services. The docker-compose.yml looks like this:
services:
backend1:
...
backend2:
...
application:
...
depends_on:
backend1:
condition: service_healthy
backend2:
condition: se... | How to make docker-compose scale start dependencies? |
IF you really don't want to download a repository, you might consider using a GitHub Action.
It does access your code on GitHub side, and can execute whatever you need.
A GitHub Action has an API, and use GitHub runner (on GitHub side, so no download on your part) as opposed to self-hosted runner.
A workflow can be an... |
I have read the following answer here about how to run a specific file.
However, let's say I want to run every single aspect of code in the entire repository here that uses MathJax without downloading it.
How would one figure that out and do that? Is it one JavaScript source code that you script?
If so, how do you fig... | GitHub Repositories (How to Run) |
We got the plugin into Gradle by addingclasspath "org.sonarsource.scanner.gradle:sonarqube-gradle-plugin:1.2"to buildscript dependencies. We then addedapply plugin: 'org.sonarqube'to activate it. Our local Artifactory instance is set up to proxy jCenter and mavenCentral. | Having recently upgraded from a previous version of Gradle, I started getting a warning that I should use the official SonarQube plugin:The 'sonar-runner' plugin has been deprecated and is scheduled to be removed in Gradle 3.0. please use the official plugin from SonarQube (the docs).From that link, I was directed to t... | Where is the new SonarQube Gradle Plugin? |
7
Using the identity pool id to create the client is a requirement, and keeping it client side is very common. It isn't a major risk on it's own, and what there is can be greatly limited with a bit of tinkering on your side.
You can mitigate the risk of exposing the ident... |
I am building a serverless website with AWS Cognito, Lambda, S3 and a dozen more of their services. My HTML/JS in my login page has the cognito pool ID. How safe is this? I know that it is best practise to hide sensitive stuff. But this is not client-server. Its all client if im honest. I do access some sensitive data... | Is it safe to show the AWS cognito pool ID in my html? |
On the install scriptsREADMEthere are steps that should resolve your scenario.Try running:pip uninstall -y virtualenv
pip install virtualenv
python .\aws-elastic-beanstalk-cli-setup\scripts\ebcli_installer.pyIf this doesn't solve the issue some additional debugging will be necessary. | I'm installing the Elastic Beanstalk CLI from Github on a Windows machine, but it keeps erroring out because of virtualenv. I get this error:C:\Users\bigji\Bootcamp\NODE\ClassActivities\EB-CLI>python .\aws-elastic-beanstalk-cli-setup\scripts\ebcli_installer.py
***********************************
1. Locating virtualenv... | Can't find virtualenv installation during eb-cli setup |
0
Your domain configuration NGINX ... It's wrong ...
Missed FastCGI Params ...
Example:
location ~ [^ /] \. php (/ | $) {
fastcgi_split_path_info ^ (. + \. php) (/.+) $;
fastcgi_index index.php;
fastcgi_pass unix: /var/run/php/php7.2-fpm.sock;
include fastcgi_params;
fast... |
The Problem
I attempted to upgrade from PHP 7.0 to 7.2 today and it resulted in websites on the server downloading through the browser instead of executing like normal.
sudo add-apt-repository ppa:ondrej/php
sudo apt-get update
sudo apt-get purge php7.0 php7.0-common
sudo apt-get install php7.2-curl php7.2-xml php7.2-... | Browser downloading PHP files instead of executing them. Webmin + NGinx |
Fixed it!
The issue I was having is the metadata for the CSS files in Amazon S3 were set to 'binary/octet-stream' by default.
The way I fixed this was selecting the individual files in the bucket, clicking the properties tab, then in the meta-data section typing in 'text/css' as the value.
|
I've been messing around with AWS lately and it definitely great. As a first test I'm trying to host the most basic static website via S3. The site is simply just one html file and a few javascript, css and image files.
Whenever I load the static URL the only thing that loads is the index.html file, its contents and f... | S3 Static Website Only Displays Index.html (but not other dependent files) |
Explanation from aSonarSource team member:In a multi-module build an aggregator plugin can't resolve dependencies from target folder. So you have two options:mvn clean install&&mvn sonar:sonaras two separate processesmvn clean package sonar:sonaras a single reactorI was surprised too, so I made atweetan received the fo... | official documentationhttp://docs.sonarqube.org/display/SONAR/Analyzing+with+Mavensays that the proper way of invoking sonar is:mvn clean install -DskipTests=true
mvn sonar:sonarbut doesn't say why. how does sonar work? does it need compiled classes? so why not justmvn clean compile? or does it need a jar file? so why ... | why sonar:sonar needs mvn install before? |
maybe calculated by coefficients * [views, stars, forks, watches ...] not just only use [stars, forks, watches] | The screenshot below is from my personal page,https://github.com/litaotaoIt shows that my popular repositories is as:guidetodataminingipython-notebook-sparkIPython-DashboardThe-Art-Of-Programming-By-JulyipydbI feel confused, for in the past long time the order was not like this, the repoIPython-Dashboardwas in order 5,... | What's the popular repositories algorithm in GitHub |
You are correct that ignore rules.gitignore,.git/info/exclude) do not do what you want.Generally speaking, there is no access control over "part of a commit". If you need actual control over whocanfetch different parts of the project, then you need to use multiple repos. (You could tie them together using submodules ... | i'm using git as a versioning system for a vr project.I've been asked to version the main vr project and the source files of the created assets, but i've also been requested to separate the two in terms of folders.What i tought is to have the main (git) project containing the folder of the vr project itself separated f... | Avoid checkout/fetch folders/files on per user config? |
Were you able to see the encrypted traffic also ?Event in SSL pinning solution traffic can be intercepted but it's all encrypted.ShareFollowansweredNov 30, 2022 at 2:01MohammedMohammed15922 silver badges77 bronze badgesAdd a comment| | I tried sniffing packets on my iOS app using Charles proxy. I added the Charles Proxy certificate on my iPhone trusted certificate store. I have the certificate transparency flag for my app turned on, which is provided by the iOS platform. I was able to sniff the packets successfully.As per my understanding, on the cli... | Certificate Transparency check failing in Charles Proxy |
5
You could use a NGINX web server to deal with the CNAME resolution problem:
User-> Varnish -> NGNIX -> ELB -> EC2 Instances
(Cache Section) (Application Section)
You have a configuration example in this post: http://blog.domenech.org/2013/09/using-varnis... |
I'm trying to put a set of EC2 instances behind a couple of Varnish servers. Our Varnish configuration very seldom changes (once or twice a year) but we are always adding/removing/replacing web backends for all kinds of reasons (updates, problems, load spikes). This creates problems because we always have to update ... | Using an AWS ELB behind Varnish - is it possible? |
Relying ondocker commitindeed amounts to a hack :) and its use is thus mentioned as inadvisable by some references such asthis blog article.I only see one possible approach for the kind of use case you mention (copy a one-time.debpackage, install it and remove the binary immediately from the image layer):You could make... | I'm trying to build a docker image avoiding unnecessary bulk, and I've run into a problem that I think should be common, but so far I haven't found a straightforward solution. (I'm building the docker on an ubuntu 18.04 system, and starting with aFROM ubuntulayer.)In particular, I have a very large .deb file (over 3G)... | docker build - Avoid ADDing files only needed at build time |
You could implement a simple cache with an LRU (least recently used) discard algorithm. Basically, set a few thresholds (for example: 100,000 items, 1 GB) and then discard the least recently used item (i.e., the item that is in cache but was last accessed longer ago than any of the other ones). This actually works pre... |
I have a UI autosuggest component that performs an AJAX request as user types. For example, if user types mel, the response could be:
{
suggestions: [{
id: 18,
suggestion: 'Melbourne'
}, {
id: 7,
suggestion: 'East Melbourne'
}, {
id: 123,
suggestion: 'North Melbourne'
}]
}
The UI compo... | How to cache results for autosuggest component? |
The WS api/ce is for internal use (as marked). It is not an API and the report it expect may change its format anytime.To submit issues based on a third party linter, I advice you look at thegeneric issue import feature. You simply have to convert your JSON file to the format we expect. | I want to upload a json report made in R using lintr package to my SonarQube server. I'm making a POST taking advantage of the api/ce/submit command (You can find it inhttps://next.sonarqube.com/sonarqube/web_api/api/ce?internal=true). To do this i'm using Postman with this params:projectKey: XXprojectName: XXnamerepor... | How to upload a report to SonarQube properly using SonarQube API |
The default capability set granted to containers does not allow a container to modify network settings. By running in privileged mode, you grant all capabilities to the container -- but there is also an option to grant individual capabilities as needed. In this case, the one you require is called CAP_NET_ADMIN (full li... | I'm trying to route all traffic of a docker container throughmitmproxyrunning in another docker container. In order formitmproxyto work, I have to change the gateway IP of the original docker container.Here is an example of what I want to do, but I want to restrict this to be entirely insidedockercontainers.Any thought... | Running docker container through mitmproxy |
You can set the name of your managed instances by setting the Name tag on the instance. At the moment you have to use the AWS CLI or the AWS PowerShell tools to do this, but once done you'll see the name in the console.You can find the AWS CLI documentation here:http://docs.aws.amazon.com/cli/latest/reference/ssm/add-t... | I have been setting up Amazon EC2 Systems Manager in order to manage our Windows patch management setup. All looking good so far as we can get the on premises servers listed in the console using the activation.I have activated the following servers on the same activation (without entering a name as part of the activat... | Change/Add Name of Managed Instance after Activation in Systems Manager |
When Erlang VM runs in an out-of-memory situation it simply crashes the whole VM. The reason is it is the most simple and safe thing to do.
If you want a fault tolerant system, you have to have more than one computer already. You can't make a fault tolerant system with only one computer (autonomous computation unit pr... |
With the "let it crash" philosophy of Erlang, one would expect the entire VM not to crash if a process cannot allocate the memory needed to proceed with its operations; indeed, if the system had a heuristic to kill some process to free some memory, some other process would handle this and recover. Root supervisors wou... | How is running out of memory handled in Erlang? |
Think of the your interaction with the retain count of an object purely as a delta.
If you increase it by one, you need to decrease it by one for that object to potentially be released.
So -- yes -- you increased it by one twice and decreased it by one twice in that code. Two releases on drain will be the result.
|
Hey, I've got a quick autorelease question. I understand basically how it works, but I was wondering if the following would create a memory leak.
NSAutoreleasePool* pool = [[NSAutoreleasePool alloc] init];
NSString* string = [[[NSString alloc] init] autorelease];
[[string retain] autorelease];
[pool drain];
Will th... | Objective c autorelease question |
Use a combination of:tail --lines=60 my_logto get the last 60 lines of your log filehead --lines=-60 my_logto get all but the last 60 lines of your log fileI'm sure you can figure the rest out :) | I've got log file, which I would like to have 60 lines in.
When there will appear 61 line, script should cut line from beginning and paste it at end of my backup log file.But I have not any idea how to do that. Can you help me? | Keep 60 lines in log file |
You can use grep in linux to fetch the relevant log messages you want:kubectl log bino | grep "error unable-to-access-website" >> John/Doe/Bino/log.txtHope this helps. | I'm new to kubernetes and am still trying to extract log from a few lines and write it, if anyone can help me what commands i should execute.If the pod is named bino, and i wanted to extract the lines corresponding to the error unable-to-access-website, and then write them to a certain location, say John/Doe/bino. How ... | Extract lines from Kubernetes log |
Use the following PromQL:label_replace(service_metric, "dbname", "${1}_monitor", "new_service_id", "(.*)") | service_metric is
{new_service_id="pgcluster"}We need a new label named "dbname" the value is "<new_service_id>_monitor"label_replace(service_metric, "dbname", "$1", "new_service_id", "(.*)") is
{dbname="pgcluster", new_service_id="pgcluster"}How to use label_replace to add a new label which value is an existing label ... | How to use label_replace to add a new label which value is an existing label value append a string |
Pretty much the same as this question:HTTP Basic Auth Exclude Single FileExcept that the other question is a little more abstract, but should fit your problem as well. | We have redirect the page from one domain to another domain, the requested domain is https(SSL certified) and its asking htaccess authentication for /favicon.ico
but the requested page is not include any code for /favicon.ico
Could you please give any solution for this? that is without asking htaccess authentication fo... | how to stop htaccess authentication for favicon.ico request |
He is wrong for any mainstream hardware I can think of. (at least in general). It could vary a little and there could be some special cases. Choose array of elements over array of pointers when you can.
CPU caches like data to be contiguously packed. Allocating each element separately will increase cache misses, slow... |
This morning I've had a discussion with a colleague about this topic. He says that it's always better to allocate arrays as arrays of pointers, since allocating every single element separately has better chances to get a free memory chunk. Somethink like this:
// Consider n_elements as a dynamic value
int n_elements =... | Array of pointers vs. array of elements |
I don't understand why Bind(SafeSplit) returns an EitherData which has a Right property I need to dereference.You don'thave to(in fact, I'd advise against it), but it compiles because the LanguageExt library comes with aBindoverload with this signature:public static IEnumerable<R> Bind<T, R>(
this IEnumerable<T> se... | I'm trying to grok how to deal with functions that turn one "Either" into many "Either"s and how you then merge those back into a single stream.The following turns one string into many numbers, squaring each and ignoring any errors. Given "1,2,Foo,4" it writes out 1,4,16.It works but I don't understand why Bind(SafeSpl... | Is there a simpler way to do this pipeline with languageext? |
You can wrap sum_over_time into sum as a workaround and query will work smoothly.E.g.:topk(100, sum(sum_over_time(m1[1h])) by(p1, p2))ShareFollowansweredMar 28, 2022 at 15:10Adam DubnytskyyAdam Dubnytskyy6644 bronze badgesAdd a comment| | I'm trying to write a query that will return the following information:for metric m1 (of type counter) - return the sum of values, grouped by (p1,p2) in a sliding window of 1h.I think the base should be something like:sum_over_time(m1[1h])but this cannot be grouped by (p1,p2)One way to do the grouping is bysum(sum_ove... | PromQL - how combine "sum_over_time" with "by" |
You have to use COPY to build your image. Use ONBUILD if your image is kind of template to build other images.
See Docker documentation:
The ONBUILD instruction adds to the image a trigger instruction to be executed at a later time, when the image is used as the base for another build. The trigger will be executed in... |
I am trying to copy files to a docker image when I execute the docker build command. I am not sure what I am doing wrong because this seems to work for the docker rails onbuild file but doesn't work for my custom dockerfile.
Here is my Dockerfile
FROM ubuntu:14.04
RUN mkdir -p /usr/src/app
WORKDIR /usr/src/app
ONBU... | Docker ONBUILD COPY doesn't seem to copy files |
You could do something like this:Create csv output stream:(Refer:)Dependency to be added (Refer to above link for the example used):<dependency>
<groupId>net.sourceforge.javacsv</groupId>
<artifactId>javacsv</artifactId>
<version>2.0</version> </dependency>Code :public void createCsv() throws Exception {
... | I've some set of objects and want to store these data as CSV file on AWS S3 bucket without creating any local file. Can anyone please suggest how could it be smoothly done without impacting performance?For Eg.:Set<Address> addresses;//Address class contains some fields as city, state, zipcode and country.It should crea... | Can we write csv file to S3 without creating a file on local in spring boot? |
The query cache was removed in MySQL 8.You can try clearing buffers, as described here:how to clear/flush mysql innodb buffer pool?However, there will be OS-level disk caching, and also hardware (HDD/SDD) caching. This makes a 2 order magnitude difference on what I'm personally testing at the moment. What you're propos... | How to disable caching queries' results for the current session in MySQL8?TheDocumentationof system variables has lot of variables that regard to caching but most of them are deprecated and I could not find any to use for disabling a query caching.I am interested in disabling caching for all statements following the di... | MySQL 8 Disable Query Cache for current session |
You can usePowerDNSwith thepipe backendto return different IP addresses dependent on the client's IP address. | I want to configure bind/write driver that resolves DNS requests based on the ip address of the client.We want to unify the domain names of all test environments for our web application.
Instead of having many domains liketest.mysite.com,qa.mysite.com, etc for different staging environments we want only to havewww.mysi... | DNS resolving based on client IP |
Using the prometheus-operator, it took me a while to figure out that the alertmanager configuration is stored as a secret inhttps://github.com/coreos/prometheus-operator/blob/master/contrib/kube-prometheus/manifests/alertmanager-secret.yamlYou would need to decode it, edit, encode and applyecho "Imdsb2JhbCI6IAogICJyZXN... | I have configured Prometheus & Grafana in GCP kubernetes Environment using the KB's provided inhttps://github.com/coreos/prometheus-operator/tree/master/contrib/kube-prometheus/manifestsAll are working perfect and my cluster details are showing in Grafana. Now I want to configure alert for Prometheus and need to integ... | Need to integrate Slack and pager-duty to Prometheus and define custom rules |
You can configure composer to use key files to access private repository.
More info: https://getcomposer.org/doc/articles/handling-private-packages-with-satis.md#security
|
My compsoser.json uses 2 private repositories from our Organisation Github Account and is as follows.
{
"name": "API",
"repositories": [
{
"type": "vcs",
"url": "[email protected]/company/private.git"
},
{
"type": "vcs",
"url": "[email protected]/company/privat... | Using Composer and Private Repository on GitHub using VCS on Build Server |
1
Try to create a classifier (Crawlers → Classifiers) and assign it to the specific crawler (Crawler Info → Tags, description, security configuration, and classifiers).
I've tried the following settings and it works perfectly:
Share
Improve this answer
... |
This question already has answers here:
AWS Glue issue with double quote and commas
(2 answers)
Closed 4 years ago.
I'm setting a new crawler that execute on schedular but fail wit... | how to fix issue with AWS crawler that split comma inside double quotes and broke data catalog? [duplicate] |
Issue this in console to set up global username and email for git:git config --global user.email "[email protected]"
git config --global user.name "Your name" | I want to use shell_exec to push to git server,How could i do?<?php
echo shell_exec('git add .');
echo shell_exec('git commit -m"update"');
echo shell_exec('git push origin master');
?>[master 9471163] update Committer: Unprivileged User Your name and email address were configured automatically based on you... | How to use PHP shell_exec upload GitHub? |
+50I've made something like that for my vhosts on my local machine. Note that everything is defined in my vhost because you can't changeupload_tmp_dirandsys_temp_dirin runtime.<VirtualHost *:80>
ServerName example.local
ServerAlias www.example.local
UseCanonicalName On
<Directory /mnt/storage/... | I am hosting multiple domains on my Apache Web Server on Ubuntu 18.04 but I cannot set the tmp upload directory for PHP.I tried putting this in my .htaccess for one of the domains, however nothing was stored when I tested.php_value upload_tmp_dir /var/www/example.com/tmp/My permissions for the /var/www/example.com/tmp/... | PHP tmp upload directory for multlple domains |
More than three levels of headingsare possible. Simply put the following in your YAML.gitbook:
toc_depth: 6However, that doesn't get you to 8, since there are only 6 levels of headers in HTML, I believe.You coulduse PARTto get to 7. Not sure how you'd get to 8, except by splitting into multiple books. | Within the navigation, bookdown only allows for 3 levels of headings. I am trying to create a book with at least 8 levels. It is very important for even the 8th level to be easily navigated to. I was thinking about solving this solution with a nested book. For example, you have your first book. Then within a page ... | How do you create a nested book within bookdown? |
Nginx Ingress controller supports rewrites and code snippets. I think what you want can be done by annotations. From the example herehttps://kubernetes.github.io/ingress-nginx/examples/rewrite/your code should look like:apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
annotations:
nginx.ingress.kubernetes... | I want to use k8s ingress to forward the domain to some service with URI. The ingress yaml just like as below:- host: foo.example
http:
paths:
- backend:
path: /
pathType: Prefix
service:
name: serviceA
port:
number: 8999
path: /foo/bar # don't... | How to forward k8s ingress domain to backend server with uri? |
EF Core 3.x included one breaking change that affects this use-case, the connection is closed earlier:Database connection is now closed if not used anymore before the
TransactionScope has been completedMitigations:If the connection needs to remain open explicit call to
OpenConnection() will ensure that EF Core doesn't ... | I am running a simple .NET Core 3.1 web application on localhost. The web application is running in a Docker Linux container (my host OS is Windows 10). The SQLite database used by the web application is connected using EF Core, is almost empty and very small at 60Kb, each table having 20 records or less, and is stored... | Every query on SQLite DB using EF Core in Docker is very slow, unless there is an explicit call to OpenConnection |
Out of the box, Sonar can't really do this: it will tell you if the total of lines has changed, but e.g., if you were to remove 1000 lines, change 1000 lines and add 1000 lines, Sonar would see that the total number of lines is the same, so no obvious change (on that metric anyway).You can get some information with the... | I would like to know if Sonar has the option to provide the report for lines of code changed/inserted/updated between the given timeframe ? | lines of code between time frame in sonar |
There is no way, that you can directly upload a plugin to sonarqube. If you want to make it wide available, you can always try to make the plugin available on theMarketplace.The question is always, what is your usecase. Are you developing a company internal plugin. Is it an Open Source Plugin worth adding to the Market... | I have created a custom rules java plugin jar and able to add this in extensions/plugins folder and restarted the server.
is there any possible way I can do it in UI directly? | Is there any possible way to add the custom created jar plugin to SonarQube in UI? |
Prometheus enables you to browse metrics by a specific tag and aggregate them.I recommend Prometheus documentation onaggregationand ontags(which in Prometheus are called 'labels').If you are asking about 'views' in something like Grafana, then they are easily configurable and you can set the filtering withvariablesfor ... | For example, I call Redis server with following command:SET key "value"After running, I want to track those 2 information at the same time:statistic of all write operators (so tag should be SET)statistic of all specific operators (so tag should be SET and key)So I will create views for tracking metrics. There are 2 way... | Observability: can we filter by tags then aggregate on prometheus or any metrics backend server |
The error messageUnable to launch provisioned product because: No launch paths found for resourceisn't super helpful. It can mean any of the following:The product doesn't existThe provisioning artifact doesn't existThe product exists but it's in a failed stateYou don't have access to the productYou don't have access to... | I'm using Javascript SDK of AWS to access Service Catalog in my Lambda function.https://docs.aws.amazon.com/AWSJavaScriptSDK/latest/AWS/ServiceCatalog.html#provisionProduct-propertyI have successfully created portfolio and product and attached the product to this portfolio. When I try to provision the product it throws... | How to add or get a launch path to a product in AWS Service Catalog using Javascript sdk |
If you import a certificate that is not a Root Certificate (self-signed) or a CA certificate (CA:true basic extension is not set) and you select "Automatically select the certificate store based on the type of certificate" in the wizard, it will get imported as "Personal" or "Other People".If you select "Trusted Root C... | I'm importing a .cer file to Chrome and Internet Explorer's certificate store.
When I'm importing it as "Trusted Root Certificate", it doesn't show any error but the certificate is found in "Personal Certificates" tab and not in "Trusted Root Certificates" tab.
Any idea about this? | Importing certificate in "Trusted Root Certificate" show up in "Personal Certificates" in Chrome/IE Cert Store |
Needs to changeWithDailyTimeIntervalScheduletoWithSimpleSchedule. Warning: there are probably better ways to deal withstartDate.DateTime startDate = new DateTime(DateTime.Now.Year, DateTime.Now.Month, DateTime.Now.Day, DateTime.Now.Hour, 0 ,0, DateTimeKind.Utc);
ITrigger trigger = TriggerBuilder.Create()
.StartAt(new... | I have a job, which triggers in every 30 minutes. I've set a test table and record information, when job fires. For example :2015-12-13 19:30:00.043
2015-12-14 12:30:00.043
2015-12-14 13:00:00.043
2015-12-14 16:00:00.043But as you can see it does not trigger in every 30 minutes. 19:30 then 12:30.. I've noticed that i... | asp.net cron job quartz.net bug, not firing always |
138
Begin the line with 0 0 * * 1,2,3,4,5 <user> <command>. The first fields are minutes and hours. In this case the command will run at midnight. The stars mean: for every day of the month, and for every month. The 1 to 5 specify the days. monday to friday. 6=saturday 0=su... |
Closed. This question is not about programming or software development. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily use... | How to skip saturday and sunday in a cron expression? [closed] |
Check first yourgit statusandgit check-ignore -v -- <directory name>/afileto see if<directory name>is tracked.If it is not tracked, then a simplerm(nogit) would be enough. | When I hit enter, it tells me "fatal: pathspec 'Directory Name' did not match any files". but the ls command brings up all the directories and it's there. Is there a special command I need to enter to get rid of a directory specifically? | The command "git rm -r <directory name>" isn't working? |
If you don't see a .gitmodule at the root of your main repository, that means your subfolder is a nested git repo, recorded as a gitlink (a SHA1 reference), which is what you see as a grayed folder.All you need to do is:delete the .git subfolder you should find in that foldergo back to the main repo (one folder up)add,... | I'm new to using GitHub and I read up a few of the solutions on stack overflow but I couldn't understand them.
I pushed a folder in one of my repository and it shows up as a gray submodule. I need it to be a regular directory inside my repo. Can someone simplify what I need to do or show steps because I don't know how... | Converting a submodule to a folder within a GitHub repo |
If you're indeed using a debian image like this one:https://github.com/docker-library/golang/blob/cffcff7fce7f6b6b5c82fc8f7b3331a10590a661/1.9/stretch/DockerfileWhich is tag:golang:1.9-stretchDebian stretch comes with python3 alreadyhttps://wiki.debian.org/PythonSo no further action is required. You would need to insta... | My docker file looks something like this:# Start from a Debian image with the latest version of Go installed
# and a workspace (GOPATH) configured at /go.
FROM golang
# Install our Go dependencies
RUN go get -u golang.org/x/oauth2...
ENTRYPOINT /go/bin/...My base application will be running on golang,but I need to acc... | How do I install python3 in docker with golang as my base image? |
GitHub uses Linguist to figure out which languages are part of your project. It has a languages.yml file to defined the multitude of languages to look for. Some are markup languages (like jupyter notebook), some programming languages, etc.
That percentage you see is calculated based on the bytes of code for each langu... |
I'm about to submit this project but I want to make sure the Github page looks good before I do. For some reason, not all the languages are showing up and I don't know why. I've tried to find ways to edit this under settings but I've yet to find anything.
As you see in the images below, on the homepage it says the Rep... | Why aren't all languages showing up in Github Repo? |
There is no official way to get your code from hackerrank, but you can use web scrapers.
Here is an implementation of ithttps://github.com/hearsid/hackerrank-scraper.ShareFolloweditedFeb 13, 2021 at 12:37DisappointedByUnaccountableMod6,72644 gold badges1818 silver badges2222 bronze badgesansweredNov 5, 2020 at 3:3821rw... | I want to upload some of myHackerranksubmissions toGitHubrepo. Can I download these at once or I have to download manually each submission from theSubmission Page? | Hackerrank - Is there a way to download all my submissions at once? |
A simple sort solved the problems, thank you everyone for the help. | I'm writing a Kibana plugin and I'm facing some problems: when I try to update a document from a React Datagrid, it ends up in the end of the index, so when the grid is reloaded it is displayed as the last element of the grid (the search is paginated).It happens for every update (not a Datagrid problem).I want it to ke... | When I update an Elasticsearch document it ends up in the end of the index |
The way I found to solve this problem was adding to the test project structure the generation of an xml with the information I needed. With the generated xml I was able to access it through a Powershell task and then save the variables as needed. | I'm running the task below in Azure Pipelines and I needed to access the percentage of tests passing and failing as a result of running this task in another task.Is this possible to be done? Can I access this result through a variable?- task: DotNetCoreCLI@2
displayName: Execute Tests
inputs:
command: 'test'
... | Is it possible to access the test execution result in a task in Azure Pipelines through a variable? |
You should definitely give a try to JaCoCo. Its integration with Sonar allows to benefit from new features, for example :merge coverage by unit and integration tests. Seehttp://www.sonarsource.org/sonar-3-3-in-screenshots/track the relations between tests and tested code (since sonar 3.5). You can find a screenshot on ... | Reasking my older question:Java test coverage: who covers what?Background: I look at sonar's coverage report for a class and want to know, which test contributes to the coverage of a specific line / branch, so that it easy to got to that test and add the test for the newly introduced if-branch.Are there other (preferab... | Free alternatives to Atlassian Clover? |
When you setrequestCert: truein yourhttps.createServer()config object, the server requests a certificate from the client for the purpose of authentication before the connection is allowed.How this is handled by the client can vary, but as you can see some browsers may present the user with a list of certificates instal... | I have installed ssl on node js server which seems working fine.Now few user are complaining about they are getting popup like this oneWhat does it mean ?Does SSL doesn't configured properly.Thanks | Google Chrome SELECT a certifcate |
1
Note that at the time of this writing, MSSQL_COLLATION only works when initializing the server for the first time (i.e. creating the master database). In order to change the server collation:
Create backups of all user databases.
Stop the old container.
Start container w... |
I'm trying to create a container with SQL Server running on with this command:
docker run -e "ACCEPT_EULA=Y" -e MSSQL_SA_PASSWORD="MyPassword1"
-e MSSQL_COLLATION="Polish_CI_AS" -p 1434:1433
-v C:/Users/User1/sql-server/data:/var/opt/mssql/data
-d mcr.microsoft.com/mssql/server:2019... | Docker - MSSQL_COLLATION not set |
Solution: Use Jest for pipelines where you cannot install a browser | I'm trying to find an alternative to generate a coverage report for an angular project with jenkins and karma, the problem comes because it is not allowed to install at least a headless browser in the CI servers of the company so Jenkins fails the job due no browser found.I know there are a lot of frameworks for testin... | Jenkins - SonarQube: Angular Test coverage karma alternative without browser |
You can use EFK(Elasticsearch fluentd Kibana) addon from k8s communityhttps://github.com/kubernetes/kops/tree/master/addons/logging-elasticsearchIt automatically collects all the stdout logs and we can see it on the kibana dashboard accessible at the k8s api URL.After creating this addon usekubectl cluster-infofor the ... | I read a lot about kubernetes logging but can not decide which one is better. My problem is that I would like to collect my container logs which are going to stdout.
My idea is to add /var/run/docker.sock to logspout (https://github.com/gliderlabs/logspout) as volume and then logspout forward the logs to logstash.
I ... | Kubernetes log collection |
This video explains what you're seeing:https://www.youtube.com/watch?v=9B4ioIlNGMkBasically you'll need to add an empty|> group()before your sort to collapse all those tables into one.ShareFollowansweredApr 21, 2021 at 9:38Peter DonkerPeter Donker33822 silver badges1515 bronze badgesAdd a comment| | Grafana 7.5.1 with InfluxDB 1.8.2. I'm trying to create a table that displays a sum of the "units" values for each distinct tag value. I am getting the data, but I need the sums to be sorted in descending order by default. This is my Flux query:from(bucket: "consumption")
|> range(start: -1y)
|> filter(fn: (r... | Why is my Flux query in Grafana not sorting by default? |
You would need some sort of program to call the Amazon S3 API to retrieve the object. For example, a PowerShell script (usingAWS Tools for Windows PowerShell) or a Python script that uses the AWS SDK.You could alternatively generate anAmazon S3 pre-signed URL, which would allow a private object to be downloaded from Am... | Is it possible to download a file from AWS s3 without AWS cli? In my production server I would need to download a config file which is in S3 bucket.I was thinking of having Amazon Systems Manger run a script that would download the config (YAML files) from the S3. But we do not want to install AWS cli on the production... | How to download a file using from s3 private bucket without AWS cli |
I did not see a way to add directly thoseGit Extensionscommands, but:You canadd to your toolbar a button for an external command.That means you can add anexternal commandcalling Git (since GitExtensions uses Git For windows)ShareFollowansweredJan 4, 2020 at 14:54VonCVonC1.3m539539 gold badges4.6k4.6k silver badges5.4k5... | I installed Git Extensions, the commands can be listed by menu , you can see Image 1.Can I display these command on a toolbar? so I can launch a command of Git quickly!Image 1 | How can I display Git Extensions menu on Toolbar in Vs 2009? |
You need to enable remote logging. Code sample below is for using S3. Inairflow.cfgset the following:remote_logging = True
remote_log_conn_id = my_s3_conn
remote_base_log_folder = s3://airflow/logsThemy_s3_conncan be set in airflow>Admin>Connections. In theConn Typedropdown, selectS3. | Pods on our k8s cluster are scheduled withAirflow'sKubernetesExecutor, which runs allTasks in a new pod.I have a such aTaskfor which the pod instantly (after 1 or 2 seconds) crashes, and for which of course I want to see the logs.This seems hard. As soon the pod crashes, it gets deleted, along with the ability to retri... | Kubernetes: view logs of crashed Airflow worker pod |
For now I moved to EC2 as EBS issues weren't getting solved.
I had the same issue on EC2 but I could fix it as I access my machine.Puma workers were timing out because my assets weren't precompiled.
Everytime I take a new build on server, I have to run the following :RAILS_ENV=production rake assets:precompile | I am new to AWS Beanstalk-Rails-Puma-Nginx.
After deploying my RAILS app to Beanstalk, all my api calls work fine, but HTML pages are causing error.When opening my HTML page -Nginx throws502 Bad Gatewayerror.Puma log :Started GET "/admin" for 182.70.76.160 at 2016-04-22 05:13:19 +0000
Processing by Devise::SessionsCont... | Puma "Terminating timed out worker" after rendering HTML |
Delete the deployment once and try applying the YAML agian.it could be due to K8s service won't allow therolling updateonce deployed thelabel selectorsofK8s servicecan not be updated until you decide to delete the existingdeploymentChanging selectors leads to undefined behaviors - users are not expected to change the s... | I have a podegress-operator-controller-managercreated frommakefileby commandmake deploy IMG=my_azure_repo/egress-operator:v0.1.This pod was showingunexpected status: 401 Unauthorizederror in description, so I createdimagePullSecretsand trying to update this pod with secret by creating pod's deployment.yaml [egress-oper... | kubernetes pod deployment not updating |
So, the answer was giver to me on ServerFault by Alexey Ten, here is a copy of the answer
Your try_files directive is too restrictive and, I guess, is in wrong place.
Either remove location / completely, it doesn't makes much sense, or, at least add $uri/ so index directive will work.
try_files $uri $uri/ =404;
But ... |
I've got this really simple server block under sites-available.
Problem: When I try to access to mydomain.com, Nginx returns a « 404 Not Found », but if I try to access to a file in particular, it works fine, like mydomain.com/index.php
server {
listen 80;
index index.php;
server_name ... | Nginx sites-available doesn't work |
You should rundocker buildfirst (which actually uses yourDockerfile):docker build --tag=imagename .Ordocker build --tag=imagename -f yourDockerfile .Then you would use thatimagetag todocker runit:docker run imagename | I'm trying to create a VM with docker and boot2docker. I've made the following Dockerfile, which I'm trying to run through the command linedocker run DockerfileImmidiatly it says exactly this:Unable to find image 'Dockerfile:latest' locally
FATA[0000] Invalid repository name <Dockerfile>, only [a-z0-9_.] are allowedDoc... | boot2docker / docker "Error. image library/.:latest not found" |
For individual filesgit add .hiddenfilefor file groupsgit add .hidden*and if in a subdirectory,git add directorywill include the hidden files in that directory.Also seeForce git to add dotfiles to repository | How do you add hidden files in like .flake8 in git? Git add . does not work and not even adding subdirectories. Gitignore is not the issue. Thanks. | How to add hidden files in Git |
Maybe you can useARGto help you, like this:Dockerfile:FROM jfloff/alpine-python:2.7
ARG src="Folder 1/File.txt"
ARG target="Dir 1/"
COPY ${src} ${target}BTW, a/has to be add at the end ofDir 1if you treat really want to treat it as a folder.And, JSON format is also ok, just you miss,, it should be:FROM jfloff/alpine-py... | In Windows 10 (cmd) I'm trying to copy a file from a subfolder containing a space character in its name.First I tried to use quotation marks:FROM jfloff/alpine-python:2.7
COPY "Folder 1/File.txt" "Dir 1"Error message:failed to process"\"Folder": unexpected end of statement while looking for matching double-quote"JSON" ... | Dockerfile: COPY / ADD with space character in path (Windows) |
When I switch the node off it automatically switches itself on again.
Not sure if I am missing something as I did not enabling autoscaling
and it's also a General Purpose e2-small instancesKubernetes nodes are managed by the Node pool. Which you might created during your cluster creation of GKE if you are using it.Node... | I'm currently testing out google cloud for a home project. I only require the node to run between a certain time slot. When I switch the node off it automatically switches itself on again. Not sure if I am missing something as I did not enabling autoscaling and it's also a General Purpose e2-small instance | Google cloud kubernetes switching off a node |
The error is because you are using a single underscore between estimator name and its parameter when using in pipeline. It should be two underscores.From thedocumentation of Pipeline.fit(), we see that the correct way of supplying params in fit:Parameters passed to the fit method of each step, where each parameter name... | I'm trying to useXGBoost, and optimize theeval_metricasauc(as describedhere).This works fine when using the classifier directly, but fails when I'm trying to use it as apipeline.What is the correct way to pass a.fitargument to the sklearn pipeline?Example:from sklearn.pipeline import Pipeline
from sklearn.preprocessing... | How to optimize a sklearn pipeline, using XGboost, for a different `eval_metric`? |
Nobody here will be able to tell you exactly why there is a difference, could be anything, starting from the time it takes to find a slot in an underlying compute cluster to the time it takes to pull the image from your container registry. As far as I know there is no SLA on the startup time.So yes, you could try diffe... | I'm using the docker compose command to spin up 2 containers in Azure Container Instances, by using ACI docker context.
Sometimes, it takes only a while (below 1 min) to get the containers up and running. However, often it takes much longer (up to 5 minutes I would say). Does somebody have an idea why the speed of ACI ... | Why it takes so long to create Azure Container Instance? |
I think this is a good practice to cut down on people who just want to poke around on your site for security holes. I mean if your student id's are sequential numbers and people are able to see the id for their page in the query string it is pretty easy to just increase the number to see if you can access the next ite... | I just came across some code that seems to encrypt database keys prior to sending them to the client (WebBrowser, Silverlight, etc).To illustrate, suppose you have a list of students to extra-curricular activities, and a relationship defined between them. Every time the data is written out to the ASPX page, the studen... | Encrypting foreign keys from database prior to sending to browser |
You just disabled the circular-reference-GC. The regular one still works.
The common GC tests, whether or not there are zvals ("memory"), that are not referenced by any variables, or properties anymore, and will free this memory. A circular reference is, when two or more objects references each other directly, or indi... |
This relates to a PHP 5.3 Cli application that processes a lot of data in a complex way, taking hours to run. Someone discovered that turning off garbage collection made it run a great deal faster (maybe as much as 50%).
The only article I've come across that mentions this performance hit is http://derickrethans.nl/c... | Why does PHP's garbage collector slow down performance, and how to manage memory without it? |
2
You can use the github API. Something like
pip install "git+https://github.com/USER/REPO@$(curl -s https://api.github.com/repos/USER/REPO/releases/latest | jq -r ".tag_name")"
would probably work for you. If you don't feel like installing jq, there's e.g. this gist.
... |
I know I can install the master branch with:
pip install git+https://github.com/USER/REPO
I also know I can install a specific release with:
pip install git+https://github.com/USER/REPO@RELEASE
But is there a way to install the latest release (the one GitHub returns at https://github.com/USER/REPO/releases/latest)? ... | pip install latest release from GitHub |
Hive running under AWS Athena is usingHive-JSON-Serdeto serialize/deserialize JSON. For some reason, they don't support just any standard JSON. They ask for one record per line, without an array. In their words:The following example will work.{ "key" : 10 }
{ "key" : 20 }But this won't:{
"key" : 20,
}Nor this:[{"key"... | Can I get help in creating a table on AWS Athena.
For a sample example of data :[{"lts": 150}]AWS Glue generate the schema as :array (array<struct<lts:int>>)When I try to use the created table by AWS Glue to preview the table, I had this error:HIVE_BAD_DATA: Error parsing field value for field 0: org.openx.data.jsonse... | aws athena - Create table by an array of json object |
will not scale to very large clusters with thousands of servicesquote refers to userspace proxy, which was the default mode long time ago before full iptables based implementation happened. So this statement is largely outdated, but...iptables mode has it's own issues that come with scale (extreamly large iptables rule... | Theofficial kubernetes docsclearly state thatkube-proxy"will not scale to very large clusters with thousands of Services", however when aLoadBalancertype Service is created on GKE theexternalTrafficPolicyis set toClusterby default (meaning that each request will be load-balanced by kube-proxy anyway in addition to exte... | using kube-proxy for load balancing |
28
Step 1: Make the Script file.
Create the script (.js) file as normal.
You might want to save in an appropriate folder, for example:
../assets/js/some-script.js
You may need to make the /assets/ folder if you do not have it.
Don't use underscore (_) at the front of the... |
Jekyll is a simple, blog-aware, static site generator for personal, project, how do i add a script tag in such ruby project.
My index.html looks like this :
---
layout: default
---
<div class="home">
<h1 class="page-heading">Posts</h1>
<ul class="post-list">
{% for post in site.posts %}
<li>
<... | How to add script tag in jekyll? |
Pushing changes to other repositories
You can add your fork as a remote:
git remote add myrepo [email protected]:adko-pl/newt.git
and push the branch in wich your changes were commited to it
git push myrepo branch
Creating feature branches
I recommend you commit your changes to a branch that is not one of the main b... |
Afraid of losing my local changes, I need your help in this scenario:
Cloned a github repository (https://github.com/nikitar/newt.git)
Applied local changes to this repo
Would like to push my changes to my newly forked repo (https://github.com/adko-pl/newt), which I have created after cloning the newt repository.
Ho... | How to switch to my newly forked repo without losing my changes |
1
I know if is only this, but in the quick glance I can say the key value in your ingress template must be pointing to the service port, not to the pod container port. Check the right config below:
kind: Service
apiVersion: v1
metadata:
name: k8site
... |
I am trying to deploy a simple HTML file to Kubernetes and host it using Nginx as a test. I am running into issues when copying over my website files.
Dockerfile
FROM nginx:alpine
COPY ./public /usr/share/nginx/html/
When I build this image and run it using docker run the website loads fine and I see my index.html fi... | COPY in Dockerfile works in docker but not in kubernetes |
There are two type of Time zone settings. One is a system level. That you can set using/etc/localtimeSee the Dockerfile steps belowENV TZ=America/Los_Angeles
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezonePS: Taken fromhttps://serverfault.com/questions/683605/docker-container-time-timezon... | I need to set the default timezone in a Dockerfile. I have two containers (nginx and php7-fpm).When I enter the PHP container's bash and runphp --info | grep timezoneI get:Default timezone => UTCdate.timezone => no value => no valueMy dockerfiles are the following:nginx/Dockerfile:FROM debian:jessie
RUN apt-get update... | Configure timezone in dockerized Nginx + PHP-FPM |
This is the easiest way, assuming you dowloaded the zip file containg the .java source files from github:
Unzip the zip file into a folder in your Eclipse workspace, say omegle-api-java-master.
In Eclipse, select New->Java Project and name it omegle-api-java-master. Eclipse will create a project from the source in yo... |
I'm rather new to java and eclipse, and I would like to get jar files from this github project:
https://github.com/nikkiii/omegle-api-java
I've tried doing so in eclipse, but I can't import the project as a java project, and (I think) for this reason I am not able to use the Export feature to obtain jar files for the... | Exporting usable .jar files from GitHub project |
The nginx docker image doesn't contain npm. You'll need to use node:latest which contains npm.
# Stage 1, based on Nginx
FROM node:latest
COPY --from=node /app/dist /usr/src/app/
CMD ["npm", "start"]
You could potentially use node:alpine to run the application.
|
I just build app: docker build . -t ang:l
after try run it: docker run -d -p 83:80 ang:l
and get error:
docker: Error response from daemon: OCI runtime create failed: container_linux.go:345: starting container process caused "exec: \"npm\": executable file not found in $PATH": unknown.
without this CMD ["npm", "star... | Can't run image, CMD ["npm", "start"] command error |
I'm not sure there is a specific way to answer yes or no. but you can append--noinputto your container command. Use the--noinputoption to suppress all user prompting, such as “Are you sure?” confirmation messages.try
command: 'source /opt/python/run/venv/bin/activate && python app/manage.py migrate --noinput'OR..
Y... | I have my Django app set up on Elastic Beanstalk and recently made a change to the DB that I would like to have applied to the live DB now. I understand that I need to set this up as a container command, and after checking the DB I can see that the migration was run, but I can't figure out how to have more controls ove... | Running Django migrations when deploying to Elastic Beanstalk |
You can use this .htaccess:RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^([^\.]+?)/?$ $1.php [NC,L] | I have a site that's built with PHP and I'm using the.htaccessfile to remove the.phpextension.RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^\.]+)$ $1.php [NC,L]This works fine and means that I can access/file.phpby doing/file. However if I put a trailing slash at the end of the URL I get a 404 e... | Trailing slash causes page to 404 |
Log on to the box/container/pod hosting Jenkins and try to ping the IP, if alls good, try to telnet to the IP AND port. Depending on the results you should know whether or not a connection is possible from your Jenkins host. Note: if you have Jenkins running in a Container On a pod, you may need to ssh into the contain... | I'm usingKubernetes Continuous Deploy Pluginto deploy and I'm using pipeline and this is stage to deploy into kubernetes in the Jenkinsfile:stage('Deploy to k8s'){
steps{
kubernetesDeploy(
configs:'quarkusAgrata.yaml',
kubeconfigId:'KUBERNETES_CLUSTER_CONFIG',
enableConfigSubstitution:true
)
... | Connecting refused while connecting to kubernetes using Kubernetes Continuous Deploy plugin |
From thedocsyou need to pass an authentication bearer token usingAuthorizationheader like below# Gets the token value
TOKEN=$(kubectl get secrets -o jsonpath="{.items[?(@.metadata.annotations['kubernetes\.io/service-account\.name']=='default')].data.token}"|base64 --decode)
# Explore the API with TOKEN
curl -X GET $AP... | Using kubernetes apihttps://${MASTERSERVER}:6443/api/v1/namespaces/default/pods --insecureto create a podGetting this error on creation:{
"kind": "Status",
"apiVersion": "v1",
"metadata": {
},
"status": "Failure",
"message": "pods is forbidden: User \"system:anonymous\" cannot create resource \"pods\" ... | User \"system:anonymous\" cannot create resource \"pods\" using kubernetes api |
I think this is feasible as number of steps. First, configure git not to prompt for a password (so that your program doesn't get stuck):GIT_TERMINAL_PROMPT=0 git clone <repository>Then check the return code of the command, and if it is valid, clone worked:retVal=$?
if [ ! $? -eq 0 ]; then
echo "Error"
else
ech... | I am having a program continuously downloading projects from GitHub and then processing them. Then I found every now and then my program stuck in the GitHub prompt for typing user account and password.My exploration about GitHub shows that these projects are no longer valid and that if I add my account and password in ... | what does return code 32768 mean in "git clone" |
Yes, that is possible. Simply move your files. I would recommend creating a single commit that only does the moves. Afterwards you can simply pull – git will figure out what to do by itself.ShareFollowansweredFeb 12, 2013 at 19:42ChronialChronial68.2k1414 gold badges9797 silver badges101101 bronze badgesAdd a comment| | I want to change the directory structure of a repository I forked on github. I mean, I will move existing directories, create new directories and move files.Afterwards, I want to still be able to pull updates from the origin repository for each of those files. Is this possible? If it is: How? | Can I change the directory structure of a forked repository but still pull new changes? |
Well, the simplest way to do this, is define a constant in your front controller (presumably, index.php):define('SECURE', true);Then, test for it at the beginning of any included file:!defined('SECURE') and exit;This will preventanyclient side access (including calling assets from the page, via JavaScript, orsrcattribu... | Only allow script to run or get request from the PHP files on the web server.For eg. you have a file on your web-severhttp://example.com/libs/comment.phpOnly allow other PHP,or JS file get request from this file (means run this file and perform desired result)If any user try a direct access to this file he/she will get... | Only allow script from server to access files |
suds caches WSDL and XSD filesfor a day by default so that each instantiation of a Client object doesn't require a separate URL request.90 seconds seems like a really long time, is that time spent waiting on the wsdl response, or is it spent parsing the wsdl? If it's taking that long to parse it, the built-in caching ... | I'm currently running python suds against a wsdl file and its corresponding 50+ xsd files. The following call toClienttakes about 90 seconds:from suds.client import Client
url = 'http://localhost:7080/webservices/WebServiceTestBean?wsdl'
client = Client(url)After I run the last line above, I get aClientinstance. Crea... | Is it possible to cache a python suds client? |
Gracefully restart the server. It won't accept new connections but will wait for the existing connections to close then restart. | We recently built out a web builder application (WYSIWYG, pre-designed templates, shopping cart etc..). We have been looking at a few different options for SSL certs, even wildcards, for a solution. The problem is we do not want to restart the server every time we have a client who wants to add an SSL to their site (We... | SSL Certificate |
I won't post a complete solution because you have identified the question as homework, but I hope I can help you out with the problem a little bit:Arrays are designed to hold many objectsof the same size. The problem with storing different objects in the array (even if they are derived from the same base class) is that... | I need help with pointers and memory management.I need to store different objects, all derived from the same base class, and have been using an array to do this but it is causing a segmentation fault when the array is populated with different objects.My program works fine when the array is full of objects of the same d... | C++, Can't use an array or vectors, how do I use a pointer to get through this mess? |
Is there any alias we can make for all-namespaceBased onthis excellent SO answeryou can create alias that inserts arguments between prefix and suffix like so:alias kca='f(){ kubectl "$@" --all-namespaces -o wide; unset -f f; }; f'and then use it regularly like so:kca get nodes
kca get pods
kca get svc,sts,deploy,pvc,p... | Is there any alias we can make for all-namespace as kubectl don't recognise the commandkubectl --all-namespacesor any kind of shortcut to minimize the typing of the whole command. | shortcut for typing kubectl --all-namespaces everytime |
Not everything needs to be optimized for peak performance. For mobile platforms energy efficiency is just as important. Out-of-order execution needs a lot of additional hardware, so it increases processor silicon size and decreases energy efficiency even though it improves single thread performance.Cortex-A53 is delibe... | I was searching about the ARM Cortex-A53 processor and i found out it uses a static in-order pipeline, in that instructions issue, execute, and commit in order. I can't understand why a modern processor like this would use in-order execution as out-of-order execution is faster as it has better handling for control and ... | Why modern processors still use in-order pipeline? |
AWS provides static IPs via NAT. The static IP is part of the AWS network, and traffic to that IP will be routed to the private IP of your instance within the AWS network. | I have created AWS Lightsail instance and attached a public IP address. So Curranty machine has 2 IPs, public and private.the command ifconfig shows only private IP and nowhere in public. Hence I am unable to bind my golang based application to public IP address.Am I missing anything here? I have spend 1 hour on chasin... | AWS Lightsail - Static IP not visible in ifconfig |
You can useandfor this:probe_http_status_code and probe_success == 0as both metrics have the same labels. The value of the alerting expression will then be the status code. | Currently I have a simple alerting rule set up that uses the "probe_success" metric from Blackbox Exporter to alert when a probe is down, kinda obvious.A requirement is that the status code of the request that failed is included in the alert. So instead of only saying "... is down", it should have the status code ("pro... | Blackbox Exporter alert with value of the "probe_http_status_code" metric |
The issue was the default way ccache checks if the compiler is the same - via its timestamp. Since each GitLab CI instance runs a brand new Docker container, this timestamp is always different, hence always building new cache.To fix this, setCCACHE_COMPILERCHECKtocontentinstead of the defaultmtime.From the ccache docum... | ccache has zero cache hits in GitLab CI, even when sources don't change and the cache is persisted.Furthermore, the cache increases in size every time a build runs, which means it is being rebuilt over and over. | No hits in GitLab CI for ccache |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.