Response stringlengths 15 2k | Instruction stringlengths 37 2k | Prompt stringlengths 14 160 |
|---|---|---|
I usedInstall Velero with HELM in GCPto install and test before answering you. So you can find myValues.yamlcontent from the article.Successful installation was performed byhelm install vmware-tanzu/velero --name velero --namespace velero -f Values.yaml --version 2.8.7 --set imageTag=1.2.0And answering your question , ... | Whenever I try to run helm upgrade on velero deployment in kubernetes(AKS) it tries to delete the CRDs of velero and fails after deleting some.helm upgrade velero vmware-tanzu/velero --namespace velero \
--set-file credentials.secretContents.cloud=./credentials-velero \
--set configuration.provider=azure \
--set ... | How can I run helm upgrade on velero deployment? |
If it is an iterative process you could set a variable$last_echowith the value oftime().
Then on each iteration check iftime() - $last_echo > 300.Example:$last_echo = time();
while (true) {
//Do process
if (time() - $last_echo > 300) {
echo '.';
}
}ShareFollowansweredSep 20, 2016 at 9:06L00_Cyph3rL00_Cyph3r66... | I have a cronjob which imports a huge file and then processes it. The import process takes a lot of time however after 600 seconds the server I am running the script on aborts the cronjob (timeout). After talking to a server technician he told me I needed tooutputsomething during the process of importing in order for t... | Is there a way to output something every 5 minutes during another process in PHP? |
To redirect only home page use:RewriteCond %{HTTP_HOST} ^recherchegoldens\.com$ [NC]
RewriteRule ^/?$ http://whitegoldenretriever.com/ [R=301,L]Make sure to test this in a new browser to avoid old browser cache. | I have a website that needs redirected, but I can't just redirect the / directory because there are other websites in folders on the server, and doing that redirects them as well. NOT GOOD!So I have my .htaccess file with a bunch of 301 redirects for individual HTML pages, and those work fine. But I need to redirect th... | Using mod_rewrite to redirect home page ONLY |
EC2-VPC instance will have VPC ID and Subnet ID attributes, the EC2-Classic one will not have it.
If you are using the dashboard, look for VPC ID or Subnet ID attribute. If using SDK/API, the VPC instances will have vpc_id and subnet_id attributes defined.
|
I have a list of EC2 instances in my AWS account. So how could I identify whether an instance is a EC2-Classic or is a EC2-VPC type of instance?
| How to know a EC2 instance is EC2 Classic or EC2 VPC instance? |
Try using these rules in your htaccess file:RewriteEngine On
RewriteCond %{REQUEST_URI} ^/admin/
RewriteRule ^ /backend/www/index.php [L]
RewriteCond %{REQUEST_URI} !^/(frontend|backend|common)
RewriteRule ^ /frontend/www/index.php | In the general structure of the site is:backend
- tralala
- tralala
- www
---- index.php
frontend
- tralala
- tralala
- www
---- index.php
common
- tralala
.htaccessDomain egwww.mysite.comCan I do something to register in.htaccess, so that when you go towww.mysite.comprocessed filefrontend/www/index.phpand then display... | mod_rewrite to redirect without changing the url in the browser? |
Don't includegit clonein the remote information box. That's a command that you might run on the command line to clone the repo.Your remote should just be the remote URL, e.g.https://bitbucket.org/user/repo | When I enter the HTTPS URL given in the Bitbucket site in Android Studio when I click "define remote" it gives me the errorRemote URL test failed: protocol 'git clone https' is not supportedI have used the SSH URL and that gives me the errorRemote URL test failed: Warning: Permanently added the RSA host key for IP addr... | I am getting the error"Remote URL test failed: protocol 'git clone HTTPS ' is not supported" when i enter the url field |
Helm seems like the way to go, but what you need to think about in my opinion is more about how will you deliver updates to your software. For example, will you provide a single 'version' of your whole stack, that translates into particular composition of infra setup and microservice versions, or will you allow your cu... | We have multiple(20+) services running inside docker containers which are being managed using Kubernetes. These services include databases, streaming pipelines and custom applications. We want to make this product available as an on-premises solution so that it can be easily installed, like aone-clickinstallation sort ... | Packaging a kubernetes based application |
To solve this issue, I created a new role from the IAM Manager console. I selected Amazon EC2 as my Service Role Type. I attached the AWSElasticBeanstalkFullAccess policy. Then when creating a new environment, I chose the new role I created. | I have created a few environments before so I know how the Amazon EBS works however lately I have been having the following issue while creating an environment:The instance profile aws-elasticbeanstalk-ec2-role associated with the environment has no role. Please attach a role to the instance profile.I follow the steps ... | AWS Elastic Beanstalk: Environment Fails to Launch |
You can try out themysqldump --user=root --port=3306 --password=topsecret --hex-blob some_database--hex-blob : Dump binary columns using hexadecimal notationDoc :https://dev.mysql.com/doc/refman/8.0/en/mysqldump.html#option_mysqldump_hex-blobJust to add, you can also run UI ofAdminerto export the data instead of using ... | I need a mechanism where i can dump the mysql which is running as a pod in the EKS cluster.By main use case is the the dump i can share to my development team so that they can restore the dump in their local(normal mysql running as service). I have seen Velero, Portworx but they only restore/dump within cluster(k8) not... | Kubernetes Dump mysql and restore Mysql |
In theapp/code/core/Mage/Adminhtml/controllers/CacheController.php, you can see thatflushAllAction()(the action that is called when you clickFlush Cache Storage) is called.This function contains the following:/**
* Flush cache storage
*/
public function flushAllAction()
{
Mage::dispatchEvent('adminhtml_cache_flus... | I understand the difference between "Flush Magento Cache" and "Flush Cache Storage" in Magento (example). I'm trying to work on a cron job that will flush the cache storage from time to time.I'm assuming that this button doesn't just remove the contents of var/cache/, but I can't find a solid resource that says what it... | Magento "Flush Cache Storage" |
FromGithub API reference for listing organizations:Note: Pagination is powered exclusively by the since parameter. Use
theLink headerto get the URL for the next page of organizations.For instance checking the 2nd page usingcurl:curl -I "https://api.github.com/organizations"gives the following link header :Link: <http... | I am trying to get all organization items throughhttp://host/api/v3/organizations?page=2&per_page=100The default size seems like 30, and 100 seems like the max limit per request.
But above link still only returns the first 100 items, i.e, not 101-200thI also tried http:host//api/v3/organizations?page=2
No matter which ... | Github v3 API get all organizations more than 100 |
This was related to compatability issues. The issue gets resolved after upgrading the jars to the latest version. | I'm getting the following exception when trying to build the sonar dashboard using maven (mvn sonar:sonar)Failed to execute goal com.github.searls:jasmine-maven-plugin:1.2.0.0:test (default) on project sample-web: There were Jasmine spec failures. -> [Help 1]
Failed to execute goal org.codehaus.mojo:sonar-maven-plugin:... | Need help on Sonar Jasmine spec failures |
You can't simply push to GitHub after a rebase because theremotehistory andlocalhistory have now diverged.What you need to do is simplypullupstream changes with--rebaseswitch:git pull --rebase upstream masterNow if you check your branch, you'll see its all well and good.git statusThen push to GitHub with a--forceswitc... | I recently tried to send a PR on github, but I soon noticed my PR included older commits:The issue here is that I only made the last commit, as the first one mentioned was merged in another PR and the second one was me updating my own branch.I asked around how I could prevent it, and most people told me to usegit rebas... | Git: How to overwrite timeline on other repo? |
According tothe documentation, if you pass an archive file from the local filesystem (not a URL) to ADD in the Dockerfile (with a destination path, not a path + filename), it will uncompress the file into the directory given.If is a local tar archive in a recognized compression format
(identity, gzip, bzip2 or xz) t... | I have a ~300Mb zipped local file that I add to a docker image. The next state then extracts the image.The problem is that the ADD statement results in a commit that results in a new file system layer makes the image ~300Mb larger than it needs to be.ADD /files/apache-stratos.zip /opt/apache-stratos.zip
RUN unzip -q a... | Docker how to ADD a file without committing it to an image? |
projectKey is simply the unique identifier of your project inside SonarQube. You are free to choose whatever you want, as long as it is unique.Analysis Parametersis the official documentation page from Sonar, where you can find additional information about all the properties.ShareFolloweditedNov 4, 2021 at 0:35RenatoIv... | What is the "projectkey" in sonar-project.properties file?sonar.projectKey=
sonar.projectVersion=1.0
sonar.projectName=How to decide the projectkey? I mean where can we find it for our.Net,plsql projects?Note- I am new to these sonar and trying to setup all these on my own in my organization. | What is "projectkey" in sonar-project.properties file |
When I created the .pem file, I simply needed to enter passphrase (min 4 char) when prompted. First, I just skipped it because I didn't want to create passphrase. It doesn't give any error or otherwise inform that passphrase is required and it actually creates a non working .pem file. | I am unable to create Apple Push Notification cert files. When I test .pem files I get an error.openssl s_client -connect gateway.sandbox.push.apple.com:2195 -cert pushapp_cert_dev.pem -key pushapp_key_dev.pemwill give an error:unable to load client certificate private key file
140735327015760:error:0906D06C:PEM routin... | Unable to load client certificate private key file |
TL;DRYou can't do this in GitHub's flavor of Markdown.Use Markdown Flavors with List ExtensionsGitHub Flavored Markdowndoesn't support list continuation. Continuations require extensions tostandard Markdownsuch asPandoc's example lists.Other Markdown flavors may support variations of global numbering, too. However, wha... | I need to continue the numbering after heading 2 as it appears here in stackoverflow. But in Github this numbering re-starts.heading 1item 1heading 2item 2 | Markdown continue numbering after headings |
2
You should have to use the relative path in backend or HTML if you are using that.
However you can do one thing
if your all request getting by the application at : www.myserver.com/core and there is no other folder exist or endpoint
you can create some redirection rules l... |
This example is specifically about Nextcloud, although I had the same (unsolved issue) in the past with others.
What I simply want to do, is to access nextcloud under www.myserver.com/nextcloud.
I am able to kind of accessing Nextcloud front page with my present setup, but everything that's not directly under the base... | Using Nginx path prefix as a Kubernetes Ingress, breaks everything under subpaths even when using rewrite-target |
Change the password of admin this way:asadmin --host localhost --port 4848 change-admin-passwordIt will prompt you with user, type "admin", admin password, retype admin passwordOnce this is done, enable the security with the following command:asadmin --host localhost --port 4848 enable-secure-adminThis should fix the p... | I am facing the same problem as mentioned in this questionHTTP Status 500 - Internal Server Error on GlassfishI do thisroot@user1:~# asadmin enable-secure-admin
No command 'asadmin' found, did you mean:
Command 'amadmin' from package 'amanda-server' (universe)
Command 'acsadmin' from package 'ion' (universe)
asadmin:... | error 500 for glassfish |
The need for it is when you have a bleeding edge release. The logic is as follows:Master always has stable code that contains new stable features that are not present in the last stable release but suitable for use in development environmentsTags show a milestone, a stable production-ready releaseDevelopment branch con... | A question related to good practices for managing a big project with Git: I hear that it is common practice to have adevelopbranch, where you do your development, to keep themasterbranch only for stable/production versions.My question is: why is this needed?I'm not asking for opinions/debates, but for the pros and cons... | Use of a long-running 'develop' branch with Git? |
Previously you could setup up Cron jobs using Google App Engine which tigger a PubSub triggered Google Cloud Function, however, this defeated the 'serverless' approach as you are introducing infrastructure to manage and it can take a moderate amount of work to setup the Cron jobs.You can now use the newly releasedGoogl... | How can I easily set up scheduled recurring tasks on Google Cloud Platform to trigger Google Cloud Functions? | How can I easily setup scheduled recurring tasks on Google Cloud Platform? |
Open Python IDLE as an administrator or CMD as administrator and load python. Aim is so that while running the program you should have administrator privilege.def blockrule():
import os
c=input('Enter Directory in the format "C:\Program Files (x86)\Common Files\"(without ""): \n')
d=input('Enter prefix: ')
e=input(... | I'm creating a service that needs to constantly monitor the Firewall to prevent unsuspecting users from removing the doors of a service. My intention is to do this using python.So, I searched for it and did not think.can I read and add rules to Windows Firewall using python? | How to Read and Add Rules in Windows Firewall with Python |
I also faced same error. On my case it happened because there were mismatched with the JDK versions with my end and the 3rd party URL which I was hitting to get JSON data. | I have a class that hits a secured URL (starts with https) with a xml and at their end it process the xml and send back the response. But while doing this i am getting some exception.javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath... | javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed |
Scoped turns out to be better than I thought, you can also use emplace which is a bit more cumbersome in this simple case but may come in handy:class A {
import std.conv;
public B b;
// We can't just use sizeof here because we want the size of the
// instance, not the reference.
private void[__tr... | According to the D specification all classes are accessed by reference which would mean that the following class would be layed out in memory as follows.Pseudocode:class A
{
public int c;
public B b;
}Memory layout of an object of type A:4 bytes | int c
(4/8) bytes | address of bIs there a way to create a clas... | Dlang - Is there a way to embed objects in objects? |
I ran across ablog postexplaining a solution for this. If you are using a query for your data you can add the column names as the first result:SELECT 'firstName', 'lastName', 'email'
UNION ALL
SELECT firstName, lastName, email
FROM users | I'm creating CSV & TSV files using AWS Data Pipeline. The files are creating just fine, but I can't figure out how to create files with column headers.At first, I expected the headers to generate automatically based on the SQL query I'm running to get the export. That didn't work, but was ok.Then I added a list of colu... | Creating column headers in CSV/TSV files using AWS Data Pipeline? |
I found three solutions for this. For multi-cluster kubernetes architecture.Linkerd:https://linkerd.io/2/features/multicluster/index.htmlConsule:https://learn.hashicorp.com/consul/kubernetes/mesh-gatewaysIstio:https://istio.io/latest/docs/setup/install/multicluster/shared/I chose Linkerd. Pretty easy to setup, good lat... | What I wantClusterA have PodAClusterB have ServiceB select PodB innamespace:defaultIn GKE(Google Kubernetes Engine)PodA in ClusterA can access ServiceB in clusterB likeapi.default.svc.cluster.clusterB.Solutions I triedGKE Internal Load Balancer:https://cloud.google.com/kubernetes-engine/docs/how-to/internal-load-balanc... | Kubernetes - Discover and access another cluster service like self-hosted |
I don't think metrics likeopa_scorecard_constraint_violationscan be exported when you're usingAzure Policies(+Gatekeeper)However you can export gatekeeper metrics, you just need to create a service monitor to hit the proper endpoint.My service monitor looks like this:apiVersion: monitoring.coreos.com/v1
kind: PodMonito... | I have enabled azure policies via terraform and applied to AKS cluster. I can see pods are deployed, up and running. I applied in-built initiativeheretoo with effect "audit" to test out how azure policies works on aks cluster.$ kubectl get pods -n gatekeeper-system
NAME READY STATUS... | Azure policies(gatekeeper) monitoring on AKS via Prometheus and Grafana |
2
As you have mentioned, memory is divided in fixed size pages (1MB or Max item configured size) and each page belongs to a particulate slab class. In the begining these pages are not actually assigned to any particular slab class. As and when requests are coming, slab clas... |
As per my understanding.
In Memcache whole memory is divided in fixed size pages and each page belongs to a particulate slab class.Each page is further divided into fixed size chunk,size of chunk is decided as per slab class.Data is stored in chunk that best suit for it(To minimise internal fragmentation).
Memcache u... | Memcache eviction policy |
5
Your config section
<add key="AWSProfilesLocation" value="C:\code\dynamodb\credentials" />
should be
<add key="AWSProfilesLocation" value="C:\code\dynamodb\credentials\filename.json" />
for it to work. In other words specify the file name in the Profile location.
If... |
I'm trying to get started developing against the local Dynamo DB service. The first step is simply creating a client:
var storedAWSCreds = new StoredProfileAWSCredentials();
This throws an exception:
App.config does not contain credentials information. Either add the
AWSAccessKey and AWSSecretKey or AWSProfileNam... | Can't create Amazon Web Services (AWS) credentials object |
Try to addException DomainstoInfo.plistiOS doesn't allow untrusted certificates if you don't add them to Info.plist.ShareFollowansweredFeb 26, 2020 at 14:33Denis KutlubaevDenis Kutlubaev15.7k66 gold badges8585 silver badges7171 bronze badges2Yes, it's added. The problem just appeared when AWS automatically renewed my c... | I have an app in the markets that was working fine until my root certificate was renewed. Now I don't know how to procede... the certificate was in AWS and if I run the app in my computer, works fine, but in my phone is not working. I sniffed the traffic and the error that I got is "User certificate is untrusted"Someon... | My app stop working after my certificate was renewed |
docker network inspect has a format option.
That means you can list all Container names with:
docker network inspect -f '{{range .Containers}}{{.Name}}{{end}}' network_name
That should then be easy, by script, to read each name and call docker network disconnect.
wwerner proposes below in the comments the following c... |
I have docker network "my_network". I want to remove this docker network with docker network rm my_network. Before it I should disconnect all my containers from this network. I can use docker network inspect and get output like
[
{
"Name": "my_network",
"Id": "aaaaaa",
"Scope": "some_value... | Docker disconnect all containers from docker network |
sqlcmd -S servername -Q "BACKUP DATABASE [DBName] TO DISK = 'C:\backup.bak' WITH INIT" | I want to back up a database using this codesqlcmd -S servername -Q "BACKUP DATABASE [DBName] TO DISK = 'C:\backup.bak'"It works. But if the backup file already exists, the data gets appended to the file instead of replacing the file. Every time I callBACKUP DATABASEthe file gets bigger.Is there an option forBACKUP DAT... | Override file while backup database |
You need to escape each one of the%:* * * * * date +"\%Y-\%m-\%d" > /home/apps/temp/env.txtOr even better, remove the quotes and leave like this:* * * * * date +\%Y-\%m-\%d > /home/apps/temp/env.txt | If I put the following incrontab -e:* * * * * date +"%Y-%m-%d" > /home/apps/temp/env.txtthere is noenv.txtcreated.If I change the above line to:* * * * * date > /home/apps/temp/env.txtenv.txtis created properly.How can I formatdatein cron? | date +"%Y-%m-%d" in crontab |
No. There's no difference as far as what becomes unreachable when.Both use a global variable that pins the API in place, so will not be collectible until the frame is unloaded and dropped from history.The second allocates and holds onto an extra activation frame (for module-localsfirstandsecond), but that's a pretty m... | I've been using two versions of a JavaScript pattern for a while that I picked up from Addy Osmani called the module pattern.view it hereThe first version of this pattern uses an object literal:var x = {
b: function() {
return 'text';
},
c: function() {
var h = this.b();
h += ' for reading';
}
}
ale... | JavaScript patterns and garbage collection |
This is documented asPseudo parameterson AWS.UsingAWS::NoValuesets the None value for the cloudformation templates. | I am writing a cloudformation template and have a parameter to take in a set of configuration values for AWS resources. One of the value isNoneas specified on the AWS documentation. However when I inputnullinto the cloudformation, the stack fails with:Template validation error: [/Parameters/.../AllowedValues/1] 'null' ... | CloudFormation specify None value for parameter |
There's nothing wrong. It is a design choice by GitHub that all the changes go via your local machine, so you fetch the upstream remote's commits, and then push them back to your own repo on your own origin remote, which just happens to be on the same server (but different repos), but git didn't 'know' that.While it wo... | I found some way to update fork from the original repo on github (let's say "jay" is name of the original repo's owner):git remote add --track master jay git://github.com/jay/repo_name.git
git fetch jay
git merge jay/masterOK, it works, but aftergit pushgit sent huge amount of data and I noticed that I did around 500 c... | Update github fork from the original repo |
shared hit essentially means the value has already been cached in the main memory of the computer and it was not necessary to read this from the hard disk.
Accessing the main memory (RAM) is much faster than reading values from the hard disk. And that's why the query is faster the more share hits it has.
Immediately... |
I'm experimenting with the EXPLAIN command and trying to find out what the shared hit is.
Seq Scan on foo (cost=0.00..18334.00 rows=1000000 width=37) (actual time=0.030..90.500 rows=1000000 loops=1)
Buffers: shared hit=512 read=7822
Total runtime: 116.080 ms
I've noticed that the more shared hit number we have the... | Shared hit cache in postgreSQL |
10
All Java objects are dynamically allocated. You're always passing around references to them. This is how the language is designed. When you do:
ClassA obj = new ClassA();
Then the object is allocated on the heap and a reference to it is stored on the stack (assuming tha... |
Why is an object initialization using the new keyword called dynamic memory allocation, since compile time itself we need to know the memory needed for that object.
Also please explain what happens when you do ClassA object = new ClassA(); in heap and stack .
| java dynamic memory allocation? |
Not to my knowledge, but I don't know that much.offlineimapis written in Python and performs both IMAP downloads and uploads. Python comes with anemail parserandimap client. Those might be a good places to start.ShareFollowansweredFeb 2, 2011 at 23:34ephemientephemient201k3838 gold badges284284 silver badges397397 br... | Google has an email auditing feature that will allow a google apps admin to bcc incoming and outgoing email (lots of options) to another account. The problem is that the email is sent the other account as an attachment. The attachment is the full email, headers and all. I would like to convert this to an email and send... | Convert google email audit attachment to an email |
You can useconcatwithsum:files = glob.glob('files/*.csv')
dfs = [pd.read_csv(file_name,index_col=0,header=None).dropna() for file_name in files]
df = pd.concat(dfs).sum()
print (df) | I am trying to iteratively add some pandas dataframe that I read from a set of csv files, and after the 16th file or so I get a memory error. The new files are pandas of around 300k rows.Is there a way to do this in the hard drive (for example with hdf5) or in a more memory efficient way?See code below. Note that sum_o... | Adding pandas dataframe iteratively in a memory efficient way |
Bucket Versioning on Amazon S3 keeps all versions of objects, even when they are deleted or when a new object is uploaded under the same key (filename).
As per your screenshot, all previous versions of the object are still available. They can be downloaded/opened in the S3 Management Console by selecting the desired v... |
I am trying to enable versioning and lifecycle policies on my Amazon S3 buckets. I understand that it is possible to enable Versioning first and then apply LifeCycle policy on that bucket. If you see the image below, that will confirm this idea.
I have then uploaded a file several times which created several versions... | Restoring files on a version enabled amazon s3 bucket |
In a very simplified form, Pragma:no-cache or Pragma:cache are now "almost" obsolete ways of passing caching instructions to client implementations, specifically browers and proxies. The way the client implementation responds to Pragma headers vary which is why the specification says it is implementation specific.
The... |
So I am sending a header in php to cache my page (this integrates into our "CDN" (contendo/akamai) as well). I always use this pragma: cache header, I've seen various examples use it as well; however, I just checked fiddler to test traffic for this .net application we developed and it says:
Legacy Pragma Header is p... | What is the Pragma Header? Caching pages.. and IE |
I haven't used them but theSonar documentationdescribes the additional properties that would enable historical analysis. Specifically it's the "sonar.projectDate" property you need to set.You haven't specified which Java build technology you're using. I've included some examples below.Finally, have you considered setti... | A while ago I setupSonarto scan a development project. The scans are invoked nightly using a cronjob. At one point I had an issue with the machine that run the cronjob and a few nightly scans were missed. I downloaded the source code from one of the days that was missed, and completed a new Sonar scan using Sonar Ru... | Injecting a Sonar analysis before an existing one |
You need to look at the pipeline object. imbalanced-learn has aPipelinewhich extends the scikit-learn Pipeline, to adapt for the fit_sample() and sample() methods in addition to fit_predict(), fit_transform() and predict() methods of scikit-learn.Have a look at this example here:https://imbalanced-learn.org/stable/auto... | I'm relatively new to Python. Can you help me improve my implementation of SMOTE to a proper pipeline? What I want is to apply the over and under sampling on the training set of every k-fold iteration so that the model is trained on a balanced data set and evaluated on the imbalanced left out piece. The problem is that... | How to implement SMOTE in cross validation and GridSearchCV |
With 100,000,000 records, you need to allow for overhead. Exactly what and how much overhead you'll have will depend on the language.
In C/C++, for example, fields in a structure or class are aligned onto specific boundaries. Details may vary depending on the compiler, but in general int's must begin at an address tha... |
How much memory do i need to load 100 million records in to memory. Suppose each record needs 7 bytes. Here is my calculation
each record = <int> <short> <byte>
4 + 2 + 1 = 7 bytes
needed memory in GB = 7 * 100 * 1,000,000 / 1000,000,000 = 0.7 GB
Do you see any problem with this calculation?
| How much memory do I need to have for 100 million records |
Seems your webserver is not configured correctly.If you're using Apache you have to addindex.phptoDirectoryIndexin your config and restart it. | I've just looked through a lot of pages to get a solution for my problem, but to now avail. The problem is extremely trivial. I have a web-page on my local server and if I write just "localhost" in browser, I see the folder structure, but I want to be redirected to index file (php). In other words, how to redirect from... | Problems with redirecting |
2
The backup script you've quoted is very old, and uses old techniques -- techniques that were old even for Oracle 9i. Even in that version, RMAN (Recovery Manager) was available and the use of RMAN is to be preferred in all cases.
See Tim Hall's excellent site for an overv... |
I'm currently learning what hot backup is on an ORACLE guide which present a generic script for hot backup. I dont understand some point of this script :
PROMPT Path to destination directory:
ACCEPT repertory
PROMPT Path for first file
ACCEPT file
PROMPT Path for second file
ACCEPT spool
SPOOL &file
PROMPT spool &spoo... | Hot backup DB script understanding |
I was able to do it like this. You need to define a network and add database and keycloak services to that network.To add the env variables you have to define them under environment block.version: '3.7'
services:
demo_db:
container_name: demo-maria-db
image: mariadb:10.5.8-focal
restart: always
ports... | I have a Maria DB docker image for my application.I've now pulled Keycloak image. It is using the default h2. But I want to use my existing maria DB imageThe documentation is asking me to create network etc, but I am not sure how I do it in cloud. So looking for a configuration based solution i.e. change Keycloak image... | How to link Keycloak docker image to MariaDB docker |
You may have noticed that if you put a Dockerfile in your home, and launch adocker buildyou will see a messageuploading context, this means docker creates a .tar with all the files in your home and in all the subdirectories, and uploads this tar to the docker daemon.If you have some huge files, this may take a long tim... | I am building a Django application with docker.
I would like to know for Django or general development work using docker, what files are typically included in the .dockerignore.
I am thinking of the following for now:.git*.pyc | What files do you typically put in .dockerignore |
Configuration API constructs key and values usingIConfigurationBuilder.Buildmethod that buildsIConfigurationwith keys and values from the set of sources registered before.If briefly, the following mechanismis implemented:Internally the specific provider is used to read from the registered source. File-based sources hav... | Currently I'm developing a .net core 2 application that should read some keys from appsettings.json on each request based on domain. (I have to mention, I have a single solution with 3 projects that share the same appsettings.json) I'm concerned about the reading time of the appsettings.json file on each request. Does ... | Is reading appsettings.json expensive? |
The $env:USERPROFILE/ ${env:USERPROFILE} syntax is specific to PowerShell.
Judging by the docs, docker-compose uses its own syntax: $USERPROFILE / ${USERPROFILE}
You report a follow-up problem, namely that the Windows-style path stored in $USERPROFILE (%USERPROFILE%) (e.g. C:\Users\jdoe\source) isn't converted to a ... |
I am searching on how to persist user profile folder in volume mounting
I have folder C:\Users\ABEL\source\repos which needs to be persisted for a windows container. The username should be from the host. It is unknown.
Below is my docker-compose file, The volume section is not correct.
Any comments will be helpful. Th... | persist %USERPROFILE% folder using docker compose volume |
This rule should do the job:RewriteEngine on
RewriteBase /
RewriteCond %{REQUEST_URI} !^/parent/
RewriteCond %{HTTP_HOST} !=domain.com
RewriteCond %{HTTP_HOST} !=www.domain.com
RewriteCond %{HTTP_HOST} ^([^\.]+)\.domain\.com$
RewriteRule (.*) /parent/%1.php%{REQUEST_URI} [L]URL will remain unchanged in browser (means... | I need some help on the htaccess subdomain to be pointed to specific file in a folder.Inside the parent folder should contain individual php files to correctly path the right applications. Sounds simple here.The url that the user has type should not change / redirect, instead it should only
"link" to the correct file a... | htaccess subdomain pointing |
+25Have you seen this error?No profiles for 'com.simnik.Friendschallenge' were found: Xcode couldn't find a provisioning profile matching 'com.simnik.Friendschallenge'.
Code signing is required for product type 'Application' in SDK 'iOS 10.1'
** BUILD FAILED **According to it - you need to use proper provisioning prof... | I am trying out TravisCI since I got it in my GitHub Education Pack.I am doing TDD on iOS 10.1.I could not yet figure out how to configure TravisCI for Swift 3.0, iOS 10.1 and using CocoaPods.I managed to link TravisCI with my Repository. But other than that, I always get a "Build Failed" message.Not sure if important,... | Using Travis CI with Swift 3.0 & CocoaPods |
but they have also been unstashed in the master branch. Is this correct?Not exactly: as long as those files aren't common with the ones versioned in master branch, switching back to master would still keep those untracked files.File added to the index shouldn't be inmasteranymore (and you should commit them tomy_new_br... | I'm new to git I've watched hours of videos and whilst it seems logical I'm failing dismally and always end up in trouble.I'm trying to stash my current uncommitted and untracked changes and 'unstash' them into a branch as per themanual. I do this:git add .
git stash
git stash branch my_new_branchIt switches to the bra... | Git - stash to branch - files in stash being re-applied to master |
I believe Jekyll (the static site generator used by GitHub Pages) is seeing{{stuff}}and trying to expand it (because it uses{{…}}to inline variables). You can prevent Jekyll from doing this by using{% raw %}{{…}}{% endraw %}in your Markdown file, but then that text will show up as-is on the GitHub repository home page ... | I use the GitHub pages feature whereby itcreates a GitHub Pages site by using the README.md file in your repository. This works well, except for one problem. In my README.md file, I have code blocks illustrating the use of GitHub Actions workflows, and inside the code blocks, references to GitHub Actions variables of t... | How to escape GitHub Actions variables within code blocks when using README.md to create GitHub Pages? |
You can add your nginx config file to your repository
mv /etc/nginx/sites-available/django /src/my_project/nginx/django
git add /src/my_project/nginx/django
Then create a symlink.
ln -s /src/my_project/nginx/django /etc/nginx/sites-enabled/django
You can do the same for your gunicorn config.
|
I'm running gunicorn and nginx on a Digital Ocean droplet. The issue I'm facing is that my config files for these services are at
/etc/nginx/sites-enabled/django
and
/etc/init/gunicorn.conf
while my code is at /src/my_project
My issue is, my source code is under source control. The config files within /etc/ aren't... | How do I include nginx and gunicorn configuration files in source control on Digital Ocean? |
Cognito is only supported via the thev2 Ruby SDK.Here is a minimal example forGetOpenIdTokenForDeveloperIdentityusing the v2 SDK:require 'aws-sdk'
cognito = Aws::CognitoIdentity::Client.new(region:'us-east-1')
resp = cognito.get_open_id_token_for_developer_identity(
identity_pool_id: 'IDENTITY_POOL_ID',
... | I am trying to follow the steps to upload files to Amazon S3 from an iOS app.According to the AWS iOS SDK docs, before uploading, it is required to authenticate the app users for secure access to AWS resources via my backend server:http://docs.aws.amazon.com/mobile/sdkforios/developerguide/cognito-auth.html#providing-c... | Upload to Amazon S3 and Calling Amazon Cognito Identity from Rails server |
What if you try using the SSH protocol for the git repository, e.g.[email protected]:xxx/yyy.git, and see if that works for you?$ git remote rm origin$ git remote add origin[email protected]:xxx/yyy.gitShareFolloweditedSep 18, 2012 at 16:05Colin R17.7k22 gold badges2121 silver badges2828 bronze badgesansweredSep 17, 20... | I am new to GitHub, but I have followed the steps to create a repo:$ mkdir fb
$ cd fb
$ git init
$ git add README
$ git commit -m 'first commit'
$ git push origin masterNow when I try to make my first commit, I get the follwowing error:$ git push origin master
error: Cannot access URL https://github.com/xxx/yyy/, re... | github file not getting committed |
To run PHP5.6 with NGINX you will need to do the following:Directory layout. All web files go in your localsrc/directoryFornginx/default.confuse the following:server {
listen 80;
index index.php index.html;
server_name localhost;
error_log /var/log/nginx/error.log;
access_log /var/log/nginx/access.... | Hello I need to setup php5.6 on my local machine. Following are the docker-compose.yml fileversion: '3'
networks:
laravel:
services:
nginx:
image: nginx:stable-alpine
container_name: nginx
ports:
- "8000:80"
volumes:
- ./src:/var/www
- ./nginx/default.conf:/etc/nginx/conf.d/defau... | I am trying to use docker for php5.6 with ngnix but there is a issue in configuration |
Step 1:Download Zip. Don't Fork the project or use git command or VCS in android studio.Step 2: Open Android Studio->New Project->Open->Select android directory.Step 3: Android Studio tells you this is a eclipse project (Convert it to gradle blah blah).Hit Next. This is the time I came to know this is an eclipse projec... | Hey I am trying to build an android application regarding google adsense.
I want to import the android sample.https://github.com/Ishaan-Kumar/googleads-adsense-examplesSince I am only interested in android I want to import only this.https://github.com/Ishaan-Kumar/googleads-adsense-examples/tree/master/androidI tried t... | Import from github to android studio |
3
The statement
var imageCache = NSCache<UIImage, String>()
creates a cache where the key type is UIImage and the objects stored in the cache are Strings. You want it to be the other way round with one caveat: NSCache doesn't support String for the key type, it has to be... |
This question already has answers here:
Download and cache images in UITableViewCell
(2 answers)
Closed 2 years ago.
I am having trouble finding a good example of how I can cache i... | how can I cache an image in swift 5? [duplicate] |
I don't think there is a way to do this as your desired. You want to map an Azure database logical server private IP to your localhostsfile, then access it via VPN gateway.You only know the public IP for the Azure database server. The public IP addresses of Azure services change periodically. You could findan IP addres... | While configuring an Azure managed Postgres service, I am trying to configure connecting from local machines through VPN.I can connect to the DB when white-listing IPs in Connection Security.
I have added the subnet the VPN-gateway is connected to to theVNET Rules– this doesn't seem to make a difference.Icanconnect to ... | Connect to Azure Database for Postgresql through VPN |
The -Xmx flag overwrites the -XX:+UseCGroupMemoryLimitForHeap flag.
The flag -XX:+UseCGroupMemoryLimitForHeap lets the JVM detect what the max heap size in a container should be.
The -Xmx flag set the max heap size to a fixed size.
To answer your example, the JVM would reserve 2500M heap space. There will be some addi... |
I'm running a containerized java application in Kubernetes.
In order to make the jvm reserve memory according to the container specifications, the flags -XX:+UnlockExperimentalVMOptions -XX:+UseCGroupMemoryLimitForHeap must be set.
If both those flags are set along with Xms and Xmx flags, what would the behavior of th... | Do java flags Xms and Xmx overwrite flag XX:+UseCGroupMemoryLimitForHeap? |
In order to achieve your requirement, you can use two copy activity in the single pipeline to copy data from two sources to respective sinks and add trigger to that pipeline in two different time.Create a pipeline with two copy activities, one for each set of data you want to copy. Configure each copy activity to copy ... | I need to run two set of data taken from database in single azure data factory pipeline at 2 different times in a day using single triggeri want to run the pipeline run twice a day, for 2 different data in 2 different times a day | i need to run two set of data in single adf pipeline at 2 different times using single trigger |
Jenkins environment URL's for git only contain the following:GIT_BRANCH
For Git-based projects, this variable contains the Git branch that was checked out for the build (normally origin/master)
GIT_COMMIT
For Git-based projects, this variable contains the Git hash of the commit checked out for the build (like ce9a3c14... | I know this isn't a "great question" to be asking, but I cannot seem to find the answer anywhere. I am working with creating NuGet packages and one of the properties I would like to auto-populate is the Project URL. I happened to notice that when configuring a Job in Jenkins and you click on 'GitHub project', a box app... | Jenkins Git Project URL Variable for use with PowerShell |
3
You can easily view all commits by a specific author with git log or gitk, just pass --all as refspec and then filter for author with --author=authorname:
git log --oneline --author=probosckie --all
gitk --author=probosckie --all
Share
Improve this answer
... |
I know that if we goto a github page like this:
https://github.com/probosckie/cssTreeShaking/commits?author=probosckie
we can get all the commits at a user level -> for a given repo. but it is only for master branch.
But how can we get all the commits by a user for a repo - across all branches?
Is there a git command ... | All user commits across different branches |
There is no global answer for this question.
It really depends on how the person implemented the function with the return value.
It may return a variable allocated on the heap and expect you to delete it
It may return a member variable pointer not even on the heap
If its return value is on the heap, TlmMsgDB may do ... |
Quick question: I am a C# guy debugging a C++ app so I am not used to memory management.
In the following code:
for(int i = 0; i < TlmMsgDB.CMTGetTelemMsgDBCount(); i++)
{
CMTTelemetryMsgCls* telm = TlmMsgDB.CMTGetTelemetryMsg(i);
CMT_SINT32_Tdef id = telm->CMTGetPackingMapID();
ManualScheduleTables.Se... | Pointers in For loops |
You can use the following syntax to make an exception:RewriteRule name_of_page_to_exclude.php - [L]The dash (-) is important. The[L]makes sure that if this rule is triggered, it's the last one that will be processed. So naturally, you'll need to place it near the top of your.htaccessfile, before the rule in your questi... | I am creating php front controller. this is my.htaccessfile.<IfModule mod_rewrite.c>
RewriteEngine on
RewriteRule (.*) controller.php [L]
</IfModule>This code redirect all url to thecontroller.php. I need to avoid redirectindex.phpto thecontroller.php. All other urls should redirect to thecontroller.php. | How to prevent one file from .htaccess redirect? |
Short answer: yes you can using the SonarQube Community IntelliJ pluginLong answer:assuming you have a build.gradle like:apply plugin: "sonar-runner"
sonarRunner {
sonarProperties {
// can be also set on command line like -Dsonar.analysis.mode=incremental
property "sonar.host.url", "http://your.son... | Has anyone succeeded in getting either the SonarQube Community IntelliJ plugin OR the 'official' SonarQube IntelliJ plugin to show results of static code analysis in Android Studio projects?The second of these requires Maven but the first of these is supposed to be agnostic.Somehow I managed to run a sonarRunner on my ... | SonarQube plugin with Android Studio |
SetSERVER_NAMEto use$hostin yourfastcgi_paramsconfiguration.fastcgi_param SERVER_NAME $host;Source:http://nginx.org/en/docs/http/ngx_http_fastcgi_module.html#fastcgi_param | My configuration file has aserverdirective block that begins with...server {
server_name www.example1.com www.example2.com www.example3.com;...in order to allow the site to be accessed with different domain names.However PHP's$_SERVER['SERVER_NAME']always returns the first entry ofserver_name, in this casehttp://ww... | nginx "server" directive with multiple "server_name" entries: always first one is passed to PHP's $_SERVER['SERVER_NAME'] |
As the the jar file will also contain the version number you better use this solutionFROM openjdk:8-jdk-alpine
ARG JAR_FILE=target/*.jar
COPY ${JAR_FILE} app.jar
ENTRYPOINT ["java","-jar","/app.jar"]ARG is there because COPY doesn't work with wildcards.And as already commented you have to call first:mvn packagePlease... | I have a Dockerfile in the root directory of a Spring Boot application and also I have a target folder in the same path as shown in below structure:|--src
|--main
|--com.abc.myApp
|--target/xyz.jar
|--Dockerfile
|--pom.xmlMy Dockerfile looks as below:From openjdk:8-jdk-alpine
WORKDIR /opt
ADD /target/xyz.jar .Wh... | Dockerfile Add command failing to locate target folder |
0
I had the same problem. I used the following procedure to accomplish the task.
Attach the MSDE database file to MSSql 2005.
Run SSMS, right click the attached database and select PROPERTIES
Select the OPTIONS page in the dialog.
On the dropdown combobox 'COMPATIBILTY LE... |
I'm trying to copy a database from ye old MSDE to SQL Server 2012 Express, since Microsoft decided not to make MSDE compatible with Windows 7. Lo and behold, when I try the osql restore from disk command, I get the message that 8.0.2055 backups are not compatible with SQL Server 2012.
How can I transfer the database ... | MSDE .BAK not compatible with SQL Server 2012? |
It seems strange that you download the Javadoc everytime...
To configure javadoc in Netbeans :Tools -> Java PlatformsChoose your JDK, the in the pane Javadoc the URL should be :http://download.oracle.com/javase/7/docs/api/If you have problem with this remove it anddownload the javadoc zipand add it instead of the url.J... | I work with Netbeans 7.0.1 for a research project. My issue is that each time I want to check the javadoc for a given function or class (from the auto-completion menu), Netbeans downloads Javadoc and caches it only while it's running. If I restart Netbeans, I have to download the javadoc again.Is there a way to tell Ne... | Netbeans Download Javadoc repeatedly |
RFC 1034 section 3.1specifies that labels (parts of DNS names) can be from 0 to 63 octets long, and the zero-length one is reserved for the root zone only. So in practice, the limits are 1 to 63 characters. | I've googled this a few different ways but I haven't been able to find anything official.What is the minimum subdomain length?From what I understand, a domain has to be at least 3 characters, but I haven't been able to find anything about the minimum for a subdomain. | Minimum subdomain length |
The GK110 devices have, by default, the L1 cachedisabled for ordinary global accesses. This means that global reads may be cached in L2 but not in L1. The L2 cache has a longer access latency than L1.If your data is read-only, and the compiler is able to discover it or you assist the compiler with appropriate decorat... | Alright, my question may be general, since I don't have a specific problem right now.However, according to my past experiences, I never saw CUDA's read only data cache outperforms other types of memory accesses such as global memory or constant memory, at the best situation, read only data cache would just be as fast a... | In which specific scenario would read only data cache outperform global memory access? |
-1OutOfMemoryError and slow startup are two different question. I think you don't have to remove your @Autowired annotation.First you should identify which bean cause slow loading (for example db connection), and add @Lazy at that class , you can reference this articlespring-lazy-annotation-use-cases. and some bean sho... | After enabling@Autowrid, Maven project with Spring 4, in approximately: 800 ManegedBeans Spring, 900 Services, 1000@Componentand 1000@Repository, the startup application trhow anOutOfMemoryError.
I increased the parameters-Xms1024m -Xmx4gin Tomcat and Wildfly, in the application I added thedefault-lazy-init = "false"p... | Tomcat 8.5 Wildfly 15 Java 8 OutOfMemoryError and very slow startup |
1
First of all, I will start on the SCM side (Github), we have a repo, we need to go into the repo and configure the hooks
As I am using the jenkins plugin generic-webhook-trigger-plugin I will set this webhook to call the specific endpoint for it:
https://myjenkins.com/... |
I am documenting my own experience, it has been long and wory but worth it, CI/CD gets more complex as our development teams mature, and we as DevOps need to act consequently, I have found a lack of clear simple instructions on how to achieve this sort of thing, so I am sharing my steps on the hope I could save some o... | How can I trigger a build in Jenkins on a Pull Request Merge event and ignore commits from a specific user? |
Turns out the variabletlsCertwas false-y (I was loading it from config with the wrong key forConfig.get()). Pulumi was smart and didn't create a secret with an empty string. | I've declared a kubernetes secret in pulumi like:const tlsSecret = new k8s.core.v1.Secret('tlsSecret', {
metadata: {
name: 'star.builds.qwil.co'
},
data: {
'tls.crt': tlsCert,
'tls.key': tlsKey
}
});However, I'm finding that when the secret is created onlytls.keyis present in the secret. When I look... | Pulumi kubernetes secret not creating all data keys |
Seems you are using too much memory?How many images do you open? Start with instruments attached and watch the memory footprint.Keep in mind that images take much more memory when loaded than compressed on disk. | Hello I'm working on an iPhone application which provides information with images and texts. In every text there is one image, which can be clicked and zoomed, shown with a UIImageViewNSString* imgName = [imgPath substringToIndex:[imgPath rangeOfString:@".jpg"].location];
UIImage* img = [UIImage imageWithContentsOfFile... | confusing memory allocation error on iPhone |
4
Use this command to list all the processes on the GPU (on Linux).
sudo fuser -v /dev/nvidia*
and find PID from the listed processes and simply use
kill <PID> .
This will kill process with specified ID.
Share
Follow
... |
nvidia-smi screenshot
The process with PID 14420 is a zombie process and its parent id is 1(init). I want to clear 4436MiB memory occupied by this zombie process without rebooting.
How should I proceed?
| How to clear GPU memory occupied by zombie process if it's parent is init? |
Quickest way I can think of is to blat the kubernetes etcd data.You will need to have "Show system containers" turned on in Docker.Please note, this issuper destructiveand not thoroughly tested (other than to see if it runs). There's probablyhorrible side effectsfrom using it. Docker for Desktop maintains a lot more st... | I am constantly creating new clusters for development and I dislike going into "Troubleshooting" every time to reset the cluster.Is there a quicker way to do this? | How to reset docker-for-mac v2.1.0.0 kubernetes from the command line? |
From your comment saying that the password that works at this prompt is your GitHub password, I strongly suspect that you've cloned your repository using thehttpsURL rather than the SSH URL. You can change that with:git remote set-url origin[email protected]:whoever/whatever.git... where you should replace the last pa... | New to Git.Followed all the directions from githubhelppages but simple commands like git pull and git push continues to prompt my password on each invocation. Specifically, I set the following:git config --global user.name "Your name"git config --global user.email[email protected]git config --global github.token 123321... | How to setup Git Bash (msysgit) with a github token or ssh key |
3
Well, if your application is the only thing running on that device, then as you mentioned, on application close the device will shut down, so no problem.
But as a better practice, I think you can use Qt's memory cleanup system. It works like this that any instance of a Q... |
I built an app using Qt. It includes some screens, and some of them are allocated dynamically.
I'm thinking whether to delete dynamically allocated objects at onBackButton() or just in their makers' destructors.
Here's the thing:
If they're deleted in onBackButton(), this will save memory because as long as the screen... | Call destructor on back button or on closing the application? |
+100Try this:<IfModule mod_rewrite.c>
RewriteEngine on
RewriteCond %{HTTP_HOST} ^mysite-blue-shirt\.com
RewriteCond %{REQUEST_URI} !^/product/blue-shirt
RewriteRule ^(.*)$ app/webroot/product/blue-shirt/$1 [L]
RewriteRule ^$ app/webroot/ [L]
RewriteRule (.*) app/webroot/$1 [L]
</If... | Let's say that I have a site running CakePHP and I have the prefix "product".I have lots of pages with URL like:http://mysite.com/produt/blue-shirt/details
http://mysite.com/produt/blue-shirt/order
http://mysite.com/produt/skate/details
http://mysite.com/produt/sun-glasses/vendorsNow I need to use a domain likehttp://m... | Use domain as "prefix" on CakePHP |
As far as I'm aware there is not currently any support in InfluxDB for exponents, which means that your equation can't be calculated.There is an open issue in github (actually 2, a "feature collection" and an individual issue) for adding this as well as a host of other enhancements, but no timeline for when it might ha... | I am trying to create a influxdb query which selects pressure values and apply a math function on them. I found out how how to apply simple calculations like /100 (see the following screenshot) which works.But I want to calculate the altitude from this pressure values. The formula for this is the following:Where p is t... | Grafana: How to implement math formula in query |
Amazon S3 uses "eventual consistency" model for DELETE operations -- meaning, your request will go through, but the actual operation may be delayed an undetermined amount of time. It has to do with the distributed nature of S3 storage. Your command needs to be propagated throughout multiple disks and, thus, may take mo... | when I try to delete a single object using S3 .NET API it sometimes takes 30 minute or more to delete the object after the request sent successfully ... and sometime it works fine without any delay.The code I am using:AwsS3Handler amazonHandler = new AwsS3Handler(System.Web.HttpContext.Current);
amazonHandler.DeleteObj... | Delay in deleting a single object in aws s3 |
I think your configuration should be correct, but it seems that this is the intended behaviour ofjwilder/nginx-proxy. See these lines in the filenginx.tmpl:https://github.com/jwilder/nginx-proxy/blob/master/nginx.tmpl#L89-L94It seems that if a certificate is found, you will always be redirected to https.EDIT: I found t... | I'm using docker on osx viaboot2docker.I have 2 hosts:site1.loc.test.comandsite2.loc.test.compointed to ip address of docker host.Both should be available via80and443ports.So I'm usingjwilder/nginx-proxyfor reverse proxy purposes.But in fact when I'm running all of them viadocker-composeevery time I try to open via80po... | docker and jwilder/nginx-proxy http/https issue |
I did setup Okta with Cognito through SAML with the following:Okta side:Single sign on URLwill be your cognito SAML endpoint in the form of:https://<yourDomainPrefix>.auth.<region>.amazoncognito.com/saml2/idpresponse(see under your user pool, "App integration" -> "Domain name" for the first part of the URL).Audience UR... | I will want to use Okta as SAML 2.0 based IDP, AWS Cognito as service provider, and Cognito user pool to have federated IDP configuration.I have followed all the steps mentioned in AWS sites listed below -https://docs.aws.amazon.com/cognito/latest/developerguide/cognito-user-pools-saml-idp.htmlhttps://docs.aws.amazon.c... | How to set up Okta as SAML IDP in AWS Cognito User Pool? |
You can use OutputCacheAttribute to affect output caching on on a controller or action-by-action basis, and use VaryByCustom.
[OutputCache(Duration = 60, VaryByParam = "*", VaryByCustom="userName")]
Place that on the controllers, then go into your Global.asax.cs and override GetVaryByCustomString:
public override st... |
I have an MVC application with approx 20 controllers.
In this application I want to cache certain views (mostly partials) for 60 seconds, i.e. the result would only change once per minute, even if the underlying data changed during that minute.
Seems simple enough.
The complication is that the partials show different... | Caching partials based on logged in user |
I was able to solve it adding a few more commands to manually download the script and execute it.
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v3
# Runs a single command using the runners shell
- name: Check current directory
... |
I have this workflow in a repo called terraform-do-database and I'm trying to use a reusable workflow coming from the public repo foo/git-workflows/.github/workflows/tag_validation.yaml@master
name: Tag Validation
on:
pull_request:
branches: [master]
push:
branches:
- '*' # matches every... | How to execute a a remote script in a reusable github workflow |
Don't try to avoid 301 caching. If you don't want any user agent to cache your redirect, then simply don't use a 301 redirect. In other words, 301 caching is here to stay, and semantically, it's a permanent redirect, so if you're planning to change the destination URL, 301 is not the right status code to use. On the o... |
This is a follow up question to Using 301/303/307 redirects for dynamic short urls, where I try to determine the best method for implementing short url redirection when the destination url will change on a frequent basis.
While it seems that 301 and 307 redirects both perform the same way, the issue that concerns me i... | Avoiding 301 redirect caching |
Per the docs there are three methods:
Using the UI: "More options" -> "Caches" on the repo's page
Using the CLI: travis cache --delete
Using the API: DELETE /repos/{repository.id}/caches
That said, Docker images are one of the examples explicitly called out as a thing not to cache:
Large files that are quick to ins... |
I cached a docker image on travis-ci. The docker image is created from a dockerfile. Now my dockerfile changed, and I need to remove caches and rebuild the docker image. How can I remove the caches on travis-ci?
My current .travis.yml looks like this:
language: C
services:
- docker
cache:
directories:
- docker_cac... | How to remove caches on Travis CI? |
In general, if you want Direct2D to interoperate with GDI, you should use ID2D1DCRenderTarget, otherwise, use ID2D1HwndRenderTarget.I am not quite understood what you said about the performance, do you mean the performance was bad when your main window lost focus? If that's the case, you can handle the windows status t... | I'm trying to port some GDI/GDI+ code to Direct2D, but I'm still a little confused about which type of target is better to use (DC or Hwnd), because I found different performance depending on whether or not I used the Gpu. In particular, I found the following problems:If I use the DCRenderTarget I can not use hardware ... | ID2D1DCRenderTarget vs ID2D1HwndRenderTarget |
According tohere - Stack Overflow QuestionPyPI will not read your package distributions for the image. You have
to use the image's external link.So change the code to:ShareFolloweditedOct 14, 2020 at 5:42answered... | This question already has answers here:How do I add images to a PyPI readme (that works on GitHub)?(5 answers)Closed3 years ago.I created a python package calledExoplanetPy on PyPI, but the pictures on the project page seem to not be rendered for some reason.
For context, the README.md displays pictures on theGitHub re... | How to create a README.md that shows pictures on PyPI? [duplicate] |
EDITThere's a simple way to do it. In your .htaccess, addErrorDocument 401 /path/to/log.phpThislog.phpis then called when a login attempt fails (you can put it behind the protected directory as well, it will be reached even though the login fails). Note that the browser doesn't know whether some resource needs authenti... | This question is related to aprevious questionI asked, but it's a different.I'm using htaccess to control login tohttp://somesite.com/folder.Once logged in, I have php code infolder/index.phpto check the username and password used to login:$_SERVER['PHP_AUTH_USER']and$_SERVER['PHP_AUTH_PW']. I log that info to a databa... | How about failed attempts for htaccess password protected directories |
You have to learn a continuous integration tool like jenkins. Jenkins has triggers to find such events. After events like below triggered. You can use variety of plugins to accomplish very different tasks.Source Code commitSource Code pushPoll bug tracker periodically.For exampleJenkins twitter pluginJenkins github plu... | Recently, I've met several bots in Google TensorFlow git repos.When I submit a PR, one TF bot finds some related groups for the PR and says, "Can one of admins verify this patch?"Then, one of a verifier bot says, I need to signup something, and I left a comment, Done. Then, the bot checked and marked it was done.Then, ... | How to add Jenkins bot and other checker bots in github? |
This is not (officially) possible. GitHub Flavored Markdown is not used for rendering markdown files in your repo, it is used only for issues and comments. So, readme files are rendered using normal markdown, and no autolinking will happen for issues, SHAs and similar constructs. | How can I reference (insert a relative link to) an issue in my github Readme.md?I found the following documentGitHub Flavored Markdownwhere it is described how to reference to an issue in a commit, but not in the readme.E.g. if the Issue is:https://github.com/user/project/issues/5how can I set a link to it in my readme... | github Readme - reference issue |
For anyone coming here :services:
myservice:
hostname: "{{.Node.Hostname}}-{{.Service.Name}}"No need to alter entry point ( at least on swarm on deploy ) | I have a service deployed to my Docker Swarm Cluster as global service (ELK Metricbeat).I want to each of this service to have a hostname the same as the hostname of the running node (host)?in another word, how I can achieve the same result in the yml file such as:docker run -h `hostname` elastic/metricbeat:5.4.1this i... | How to set hostname in global service in Docker Swarm |
Finally, I figure out how to copy it and use the environment variable. Here is. the updatedYAMLfileapiVersion: apps/v1beta1
kind: Deployment
metadata:
name: my-app
spec:
template:
spec:
volumes:
- name: google-cloud-keys
secret:
secretName: gac-keys
containers:
- name: ... | I am usingFirebasein myGoLangproject hosted onGoogle Kubernetes Engine.Steps I followed:Enable firebase admin SDK on the firebase account. It generated a service accountJSONfor me. This also created a service account under my Google console service credentials.Followed thisanswerand add a new secret key usingkubectl cr... | How to set up an environment variables on google kubernetes engine? |
Being part of a domain is a pre-cursor for installing MSMQ in AD-integrated mode.
It doesn't guarantee MSMQ IS installed in AD-integrated mode.
MSMQ will install in workgroup mode if:AD integration was not selected as a setup optionAD integration was selected but failed to initialise; check event logsYes, the workgroup... | My computer is connected to a domain, but when I go to create a public queue:MessageQueue.Create(@".\testqueue");I get this error:A workgroup installation computer does
not support the operation.Why might MSMQ think I'm on a workgroup computer? | Why does MSMQ think I'm on a workgroup computer? |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.