Response stringlengths 15 2k | Instruction stringlengths 37 2k | Prompt stringlengths 14 160 |
|---|---|---|
I think that's one explanation:
link text
|
In the terms of Apple's Documentation: What does "Memory Footprint" mean? How much Memory my App consumes? Does someone have a good explanation for that term?
| What describes best the term "Memory Footprint"? |
As pointed out in comments, you probaly want this.#!/bin/bash
from_directory="first_directory"
to_directory="second_directory"
rsync --archive $from_directory $to_directory; ls -R $to_directory/$from_directoryAnd if$from_directoryand$to_directoryare both absolute paths,$to_directory/$from_directorydoes not make sense... | I want to write a easy script shell like that:#!/bin/bash
from_directory="first_directory"
to_directory="second_directory"
rsync --archive $(from_directory) $(to_directory) | ls -R $(to_directory)/$(from_directory)ORcp -r $(from_directory) $(to_directory) | ls -R $(to_directory)/$(from_directory)I have this error ==>... | Write a bash script that lists all files and subdirectories |
I can suggest two options for you.Just delete entire directory and clone the code from GitHub again, as if it is your first time.But, if I were you, I commit my changes into my branch withgit add .andgit commit -m "Tried so and so, but will put this off for a while and come back later."commands. You never know when you... | So I am working on a project for school using GitHub. What I am trying to do is basically wipe my branch, or completely override it so it is identical to the current master BranchI have done some research on how to do this but I am unsure what the best way to do this is. I'm basically brand new to Github so I just want... | Completely overriding Github branch with the Master branch |
Does nginx run on windows?I think you'd have a much better result using an existing library that includes a good http server. My first choice would belibevent. | The application runs in Linux, Windows, Macintosh.Also, if yes, how much effort is required? | Is it possible to embed nginx in a C/C++ application |
Per the answer you linked, the "archive" operation is made by creating tags on each branch to be archived and then removing such a branches. So, after all you have no branches, you have only tags.
To list all tags with archive prefix in the name you can use
git tag -l "archive/*"
(note the archive part of command - i... |
Is there a way to see all the branches that are archived?
I used this answer to archive some of my branches.
and there's a way to restore the branch after I have archived it, but only if I know the name. If I don't know the name, is there a way to see all branch names that have been archived?
some sort of
git branch -... | How to see all archived branches in Git |
What if you:find API server by runningkubectl cluster-infolook into smth likeKubernetes master is running at ... lets say from the examplehttps://EXAMPLE0A04F01705DD065655C30CC3D.yl4.us-west-2.eks.amazonaws.comtranslate thathttps://EXAMPLE0A04F01705DD065655C30CC3D.yl4.us-west-2.eks.amazonaws.comto ip address, lets say ... | In our EKS Kubernetes cluster we have a general calico network policy to disallow all traffic. Then we add network policies to allow all traffic.One of our pods needs to talk to the Kubernetes API but I can't seem to match that traffic with anything else than very broad ipBlock selectors. Is there any other way to do i... | How to create a network policy that matches Kubernetes API |
To ensure that we can scale to multiple nodes but keep up interconnectivity between different clients and different servers, I use redis. It's actually very simple to use and set up.What this does is creates a pub/sub system between your servers to keep track of your different socket clients.var io = require('socket.io... | I am involved in a development project of a chat where we are using node.js, socket.io (rooms) and mongodb. We are at the stage of performance testing and we are very concerned if the system needs a load balance.How can we develop if our project needs it? J'a researched on NGINX looks cool, but we are in doubt whether ... | Chat project - load balance with socket.io |
The client use thekloglibrary that implement thedefault logging conventions. You could read more in thereadme.You should initialize the library with different values in your main.As example:import (
"bytes"
"flag"
"fmt"
"k8s.io/klog/v2"
)
func main() {
klog.InitFlags(nil)
flag.Set("logtostderr"... | I am using the go discovery client pkg (k8s.io/client-go/discovery,v0.22.2) to list all supported resources in a cluster ->discoveryClient, err := discovery.NewDiscoveryClientForConfig(GetK8sConfig())
if err != nil {
// do something
}
resourceList, err := discoveryClient.ServerPreferredResources()When I run this... | How to prevent Kubernetes go-client-discovery pkg sending error to stderr |
You can't specify a query string like this.In this case, the interpreter looks for the literal file "download.php?multiclient=true", it doesn't interpert the part after the question mark as query string.A simple solution would be to change your cronjob to make a http request instead of trying to invoke the interperter ... | I've been running aCronjob successfully with the following command:php -q www/download.phpHowever the job fails to run if I add a query string, like this:php -q www/download.php?multiclient=trueI've tried, without success, putting the file path of the command in single quotes like this:php -q 'www/download.php?multicl... | Query string is preventing a Cron job from running |
It is actually sensible to associate Redis and MongoDB: they are good team players. You will find more information here:
MongoDB with redis
One critical point is the resiliency level you need. Both Redis and MongoDB can be configured to achieve an acceptable level of resiliency, and these considerations should be disc... |
The Setup:
Imagine a 'twitter like' service where a user submits a post, which is then read by many (hundreds, thousands, or more) users.
My question is regarding the best way to architect the cache & database to optimize for quick access & many reads, but still keep the historical data so that users may (if they wan... | Architecture for Redis cache & Mongo for persistence |
8
Just ran into this issue too - the Service Name must be 's3' vs 'S3'.
advanced authorization settings
Share
Follow
answered Jul 2, 2021 at 18:16
Brandon CrowellBrandon Crowell
8111 silve... |
Unfortunately i cannot use AWS SDK and i must use REST API AWS services(i am working with Flutter WEB).
So i start to do research on aws docs and this is what i did:
Create bucket.
make all permission to be public(for test only)
open access point
Then at the postman i am using at "Auth" aws signature and added cu... | AWS Upload file to S3 REST API - Missing required header for this request: x-amz-content-sha256 |
Not so far, i was in exactly the same situation. To my mind, you're trying to deligate mailing from exactly "at posting moment" to scheduled timetable. So that, first that you need to know is:WHEN YOU'RE RUNNING CRON YOU HAVE NO ACCESS TO $_SERVER, $_POST, and other global variablesThat's because you run PHP, NOT throu... | My webhost supports cronjobs. I am very new so I hav almost no idea what I'm doing. I scheduled cron to run a script that sends an email. But I don't know what to do! Here's my cron:0 0 28 * * php -f /home/a7269592/contact.phpNow how could I adjust my code so when It's the 28th, that code will send out an email. Here'... | I finally was able to use cron... but I'm not sure if it will work with my code. How can i change it? |
I suggest you to fix the committer. Remember that there is a difference between the user who commit, and the committer. The committer is signed inside.git/configfolder:$ cat .git/config
[user]
name = John Doe
email =[email protected]Now, you just need togit commit --amendandgit push origin BRANCH -f. The forme... | I want to know if there is a way to change the person(account) who pushed changes in a GitHub repository.For example: I push to my private repository under a different name(not email) but I misspell one letter of my name and GitHub marks the commit as commited by userame not username; | How to change the author of a commit in GitHub? |
Anything I can do to get that back?
No. The unit of preservation in Git is the commit. Anything not committed is transient.
|
I was performing a git rebase before working on my changes. Unfortunately I didnt finish the rebase and without realising rebase was in progress I started working on my changes. Later when I was building I realised rebase was in progress causing a bunch of conflicts so i did git rebase --abort and lost my working chan... | How undo a git rebase --abort? |
If you have the private key, you can retrieve the public key.
If you are using Linux, use following command,
ssh-keygen -y
Then provide your path to private key file when prompted.
After that you will be given a public key. Save it.
Then use following steps to regain access to this instance.
Stop your instance
Detac... |
So, it seems a developer on our team deleted the public key for our App-Production.pem key in our .ssh/authorized_keys, so the default AWS Key Pair no longer works, breaking our deployment pipeline.
Where can I find the public key to add back to authorized_keys? Is it possible to do this without having to boot a fresh... | How to find AWS keypair public key? |
I answered asimilar question oncebut would like to highlight some points:Use VPC with proper Security Groups setup (must) and network ACL (optional).Notice your private keys distribution. AWS made it easy with storing it safely in their system and never using it again on your servers. It is probably better to use self-... | We have a web application running on ec2 instance.
We have added AWS ELB to route all request to application to load balancer.
SSL certificate has been applied to ELB.I am worried about whether HTTP communication between ELB and ec2 instance is secure?
or
should I use HTTPS communication between ELB and ec2 instance?D... | Is ssl termination at AWS load balancer ELB secure? |
The cookies are set on specific domains. Ex:setcookie(name,value,expire,path,domain)When you log in on gmail, before "mail.google.com", you have been redirected to "accounts.google.com" then to "mail.google.com" so the cookies are on "accounts.google.com" too.In this case, the domain is "accounts.google.com" and the pa... | I don't understand how google achieve the following mechanism of single sign on:I login in gmail for example (I suppose this creates a cookie withmy authorization)I open a new tab and direct type the url of "youtube"Then I enter youtube logged in.How can this second site detect that I've already been logged in.
They ar... | Automatic cookie single sign on on multiple domains - like google |
Does anybody know if there is a alternative for azure devops
pipelines?If the alternative you mentioned means some tasks in Azure DevOps pipeline can do the similar thing as 'ankane/setup-mariadb@v1' in GitHub,then the answer is NO.DevOps doesn't have a 'build_in' task like this, even the marketplace also doesn't have ... | I want to migrate my github action pipeline to azure devops, unfortunally i wasn't able to find an alternative to the github action "ankane/setup-mariadb@v1".
For my pipline I need to create a local mariadb with a database loaded from a .sql file.
I also need to create a user for that database.
This was my code in my g... | Azure DevOps Pipeline local MariaDB |
To fix the issue above, I had to specify the namespace in the following line:handler := clientset.CoreV1().Pods("my-namespace").PodInterfaceThis fixed the error, because it is not allowed to create a pod outside an namespace. So, even if the namespace was provided in the pod object, it also must be specified 'as a flag... | Programmatically creating a pod using the Kubernetes client-go gives me the following error:an empty namespace may not be set during creationStarted from this example:https://github.com/feiskyer/go-examples/blob/master/kubernetes/pod-create/pod.go#go
handler := clientset.CoreV1().Pods("").PodInterface
pod := apiv1.Po... | kubernetes client-go error: an empty namespace may not be set during creation |
Theaws s3 synccommand has a--size-onlyparameter.Fromaws s3 sync options:--size-only(boolean) Makes the size of each key the only criteria used to decide whether to sync from source to destination.This will likely avoid copying all files if they are updated with the same content. | Lately, we've noticed that our AWS bill has been higher than usual. It's due to adding anaws s3 synctask to our regular build process. The build process generates something around 3,000 files. After the build, we runaws s3 syncto upload themen masseinto a bucket. The problem is that this is monetarily expensive. Ea... | More efficient use of aws s3 sync? |
If you're using MSYS-based bash on Windows, make sure you prefix with
MSYS2_ARG_CONV_EXCL=*
to prevent it from expanding /prefix/prefix2 to a windows path. | I am trying to query some SSM parameters by path (within Gitbash):aws --region eu-west-2 --profile some-profile ssm get-parameters-by-path --path /prefix/prefix2There are a number of parameters that exist which match this prefix, e.g./prefix/prefix2/p1
/prefix/prefix2/p2
...I am getting the following error back:An erro... | Why am I getting an error when querying SSM parameters via get-parameters-by-path? |
The reason why it is not recommended for production is because the chart provides a very basic Postgres setup.In container world containers are transient unlike processes in the VM world. So likelihood of database getting restarted or killed is high. So if we are running stateful components in K8s, someone needs to mak... | I am new working with Airflow and Kubernetes. I am trying to use apache Airflow in Kubernetes.To deploy it I used this chart:https://github.com/apache/airflow/tree/master/chart.When I deploy it like in the link above a PostgreSQL database is created. When I explore the value.yml file of the chart I found this:# Configu... | Postgres subchart not recommended for production enviroment for airflow in Kubernetes |
There isimport. Read uphere. Example:import -window root -delay 200 screenshot.pngyou can write a script to randomize. | It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened,visit the help center.Closed11 years ago.I want automatic screenshots to be take... | Linux: Take automatic screenshots at random times [closed] |
The solution should not require additional CI/CD software (e.g. Teamcity), but I'm OK to write some scripts, and should be integrated into Github.That kind of integration is calledGitHub Actionsand will use aworkflow filethat you put in your GitHub repository.You can therefore adaptvsoch/pull-request-action, which can ... | I'd like to enable auto merge ONLY fordev->staging(i.e. merged fromdevtostagingbranch) and immediately after someone pushes anything todev. Because merges come from PR, this PR should also be automatically created. The solution should not require additional CI/CD software (e.g. Teamcity), but I'm OK to write some scrip... | Github: Automerge immediately after a push and only for selected branches |
I have managed to resolve issue myself. After inspecting certificate files I found out that the provided client certificate fileclient.pemcontained both client certificate and private key. Https agent created with https module requires private key to be specified separately askey, modifiedhttpsAgentshould look like thi... | I have been trying to implement working curl request in Axios (Node.js) but with no success.Working curl request looks like this (I can't share exact request as API is private):curl --cacert server.pem --cert client.pem:123password456 -i -H "accept:application/json" -H "content-Type:application/json" "https://example.e... | Curl to Axios in Node.js - Problem with implementing working curl request with provided certificates - ECONNRESET / Socket hang up error |
git push -u origin developSpace not slash '/' between repo and branch. That is why it says "'origin/develop' does not appear to be a git repository" because it's trying to find a remote called origin/develop, which doesn't exist (the remote is called origin). | I am a new git user.I am using the git version 2.8.2.I have access (to push /pull ) to a private repository.I cloned the repo using https ( not SSH )git remote -v
origin https://github.com/UserLab/project.git (fetch)
origin https://github.com/UserLab/project.git (push)I want to be able to push/pull to/from develop b... | Could not read from remote repository https |
disclosure: I used to work on Amazon SNS
The architecture you propose is a common pattern within Amazon SNS and is sound.
You should ask for a topic limit increase. There is no cost implication for having a higher topic limit, even if you create the topics and don't use them. However, you will pay $0.50/million reques... |
I am developing an architecture for push notifications using AWS SNS with APNS and GCM. The model that I am following is
Each user (not device) will have an SNS topic corresponding to it
Each user can have multiple devices
Create an platform application endpoint for each device
Subscribe the platform application endp... | AWS SNS workaround for 100,000 topics limit |
You can't do this. Put simply: in someone else's browser, this isn't your decision to make. | I am trying to make a Https post request to an url having an expired certificate. Is there a way to bypass that security in Javascript? I was able to do it in C# and Java.function post()
{
var xmlhttp;
xmlhttp = new XMLHttpRequest();
xmlhttp.open("POST","https://something.com:8443/trigger",true);
xmlhttp.setRe... | Bypass Certificate expiration in javascript |
Well it's not the queue that is TLS/SSL enabled. It's the connection (i.e. channel) to the queue manager that is TLS/SSL enabled. You can create another channel that is not TLS/SSL enabled and connect to the queue manager to get messages from that queue. | We have a .NET application which reads from Websphere MQ.
The queue is local, and is managed using MQ Explorer.
The queue is authenticated using SSL certificates.We would like to read from the same queue from an application being written in Java. I understand that in order to access the queue using JMS, we would need t... | Disabling authentication using Websphere MQ Explorer |
There is no intrinsic way to require this. However, you can use a CI check, such as a GitHub Action, to read the PR text from the API and require it to mention an open issue, which will prevent it from being merged without containing the expected text.However, as for closing a pull request without merging it, such as ... | Is there a way to force an issue to be linked to a PR before allowing the user to merge/close the PR? I was able to set up all of the other checks in the branch protection rule, but I cannot find a way to check that there is at least 1 linked issue. | How do I require a linked issue in a github pull request before allowing the PR to be merged/closed |
I found a way to workaround, seams that meterRegistry keeps the fist value you put, but you can remove the previous value and register one more time, I don't know if is the best way, but solves the problem to mepublic void percentage(String name, AtomicReference<Double> value) {
try {
var m = meterRegistry.get(name);... | I have aSpringBoot 2.2.4.RELEASEwith a RestRepostory likeimport io.micrometer.core.instrument.Gauge;
import io.micrometer.core.instrument.MeterRegistry;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;
import javax.annotation.PostConstruct;
@Rest... | Spring boot prometheus micrometers - Gauge not updating |
From the docsherea PVC is bound to a PV which has got enough capacity to satisfy the PV.Also claims can specify a label selector to further filter the set of volumes. Only the volumes whose labels match the selector can be bound to the claim. This is documentedhere | I am create a pv in kubernetes v1.16.0 cluster like this:apiVersion: v1
kind: PersistentVolume
metadata:
name: nfs-flink-pv1
namespace: middleware
spec:
capacity:
storage: 5Gi
accessModes:
- ReadWriteOnce
nfs:
server: "192.168.64.251"
path: "/mnt/data/flink"
persistentVolumeReclaimPolicy: Re... | how pvc decide which pv to bound in kubernetes |
Turns out that the issue was in the NodePort service that was accepting traffic from outside. Services by default are load-balancing traffic across the pods, so sometimes connections were routed to the other regionistio-ingressgatewaypod.
Simply addingexternalTrafficPolicy: Localto the service that is accepting traffic... | Unable to configure Locality-prioritized load balancing.
There are two nodes with the labels:labels:
kubernetes.io/hostname: test-hw1
topology.kubernetes.io/region: us
topology.kubernetes.io/zone: wdc04labels:
kubernetes.io/hostname: test-hw2
topology.kubernetes.io/region: eu
topology.kubernetes... | Istio Locality-prioritized load balancing not working |
If you are using the default cache store, i.e. the FileStore or the MemoryStore, deleting only a subset of keys should be possible with the delete_matched method, e.g.:
Rails.cache.delete_matched(/^google\.com/)
If you are using memcached, it is not possible and you would have to manually delete all keys exactly as u... |
We have:
Rails.cache.fetch("google.com/videos", expires_in: 12.hours) { # some request }
Rails.cache.fetch("google.com/images", expires_in: 12.hours) { # some request }
Rails.cache.fetch("stackoverflow.com/questions", expires_in: 12.hours) { # some request }
How can I get rails cache be expired by "google.com" key or... | How to manually expire rails low cache by namespace |
An EC2 instance is like a remote computer running Windows or Linux and on which you can install whatever software you want, including a Web server running PHP code and a database server.
Amazon S3 is just a storage service, typically used to store large binary files. Amazon also has other storage and database services... |
Closed. This question does not meet Stack Overflow guidelines. 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 used by prog... | What is the difference between Amazon S3 and Amazon EC2 instance? [closed] |
I wouldn't mix application logic (URL routing) into your HTTP server. Lots of PHP apps used to rely on Apache .htaccess files for this sort of thing. It ends up being a mess.
As you mention, it would require restarting Nginx to change routes, and it would also tie your application to Nginx, unless you wanted to rew... |
I'm currently messing around with making a custom MVC framework for educational (and, if it's good, actual practical) use, and I like to investigate different scenarios for possible performance boosts.
When it comes to URI routing, I'm familiar with the standard URI format of
/controller/action/id
And parsing the dat... | MVC Routing - Using NGINX to route instead of PHP (or Ruby, etc.) |
This is typical of a new repo created on GitHub sidenon-empty(meaning with aREADME.mdorLICENSEor...)If you try and create a GitHub repo actually empty, you won't see that error message and won't need to do agit pullbefore yourgit push. | I tried lots of times but all failed. My steps shows belowadd SSH key from cloud9 at my github and connect cloud 9 with my githubnew a repo called[email protected]:XXX/XXX.gitenter the file in cloud 9git remote add origin[email protected]:XXX/XXX.gitgit push -u origin masterWarning: Permanently added 'github.com,1... | How to push the code from cloud9 to Github? |
3
Add a / in front of your img folder, like this:

I just tried it on a test github pages page and it worked for me.
Source: official Jekyll documentation example: https://jekyllrb.com/docs/posts/#including-images-and-resources.
In... |
I managed github to run my index.md through Jeckyl and display it under github.io by following https://help.github.com/articles/creating-project-pages-manually/. However, my images links of this form:

don't show as they did in README.md
Can I use images together with... | Can I use markdown to link to images on github pages? |
Runapk updatefirst.A complete example:ole@T:~$ docker run -it --rm alpine /bin/ash
/ # apk update
fetch http://dl-4.alpinelinux.org/alpine/v3.3/main/x86_64/APKINDEX.tar.gz
fetch http://dl-4.alpinelinux.org/alpine/v3.3/community/x86_64/APKINDEX.tar.gz
v3.3.1-97-g109077d [http://dl-4.alpinelinux.org/alpin... | When running an alpine docker container for the first time and attempting to installopenssh, I get the following error:ole@T:~$ docker run -it --rm alpine /bin/ash
/ # apk add openssh
WARNING: Ignoring APKINDEX.d3812b7e.tar.gz: No such file or directory
WARNING: Ignoring APKINDEX.bb2c5760.tar.gz: No such file or direct... | How to install OpenSSH on Alpine? |
After a couple of days trying, and a big help from the QuotaGuard guys, i solved it:QuotaGuard works by overriding DNS lookup so my server connections goes to my local machine, where a process will redirect all traffic to my remote server, that will connect through the right IP.But it seems like oracle drivers don't se... | I'm writing a Rails application that needs to connect to an Oracle database inside a company firewall. Thus, i need to connect to their VPN or at least use a static IP address to make all my connections.I've triedProximoandQuotaGuardwithout success. I make all required configs, but no matter what i do, the firewall say... | Problem connecting to Oracle db inside heroku through a static IP |
If you created your data by running DATA LIST with inline data, you could find this in the journal file, which is on by default. However, if the data were entered in the Data Editor but not saved - I can't guess how that could happen - there would be no backup. | Does SPSS automatically create a backup of data files?I require that because the data that was entered for a long time in SPSS was not saved, even with using Ctrl+S for many times during data entry. | Auto-backup of SPSS |
Options:AWS Toolkit for Visual Studio Code usesthis classto visualize the Amazon States Language.There's an NPM module,aws-sfn-graphthat can do it.And, of course, you could build something yourself... | Let's say I have a json representation of an AWS Step function state machine (Such as the provided example here:https://docs.aws.amazon.com/step-functions/latest/dg/concepts-amazon-states-language.html).
This can be visualised as seen on AWS when I check the definition, and can be rendered as well in the VSCode AWS Plu... | How can I render an Amazon States Language json to an image? |
GitHub appears to serve the audio with a video tag, if you go to the link to your audio file you will see something like this:<video controls="" autoplay="" name="media">
<source src="https://user.github.io/project/audio/sound.mp3" type="audio/mp3">
</video>A bypass I've found is to link to the raw mp3 file availab... | I was making a github repository with a HTLM5 file and a mp3 file.On the html file i writed:<script>
var audio = new Audio('sound.mp3');
audio.play();
</script>And then i uploaded in the repository a mp3 file, imagine if the file name wassound.mp3.Here's what the files look like:index.htmlsound.mp3The problem is that t... | How to play sounds in github? |
You have to configure plenty things to make jacoco works. Check that configuration:<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>0.6.2.201302030002</version>
<executions>
<!-- prepare agent for measuring unit tests -->
<execution>
<id>prepare-unit-tes... | Maven 3.0.4sonar-maven-plugin 2.2jacoco-maven-plugin 0.6.4.201312101107When I runmvn sonar:sonar, theprepare-agentgoal of the jacoco-maven-plugin fails to run, so the agent arguments aren't there for surefire when needed.When I explicitly runmvn prepare-package sonar:sonar, I get an infinite recursion in jacoco initia... | sonar, jacoco, and maven are not cooperating for me |
I have restricted HTTP access to an Elastic Beanstalk application to only certain IP addresses.Following is my procedure.Create new beanstalk environment in the VPC(Amazon Virtual Private Cloud).Please read following documents.Using AWS Elastic Beanstalk with Amazon VPCExample: Launching an AWS Elastic Beanstalk Applic... | Is it possible to restrict HTTP access to an Elastic Beanstalk application to only certain IP addresses? I"ve tried adding rules to my environment's Security Group but these don't appear to be having any effect. Is this because all HTTP traffic is routed through the Elastic Load Balancer, whichisn'twithin the security ... | Restrict HTTP Access to Elastic Beanstalk |
32
If the instance was started in the last 90 days, you can get the information you want from Cloudtrail dashboard.
If the instance was started more than 90 days ago: If you have Cloudtrail enabled and configured it to write to S3, then you can go through the Cloudtrail l... |
One of our EC2 instance went missing from running instance list, probably it got terminated accidentally by someone.
In cloudtrail events, I can see some terminate instance events along with event time, user and instance id's which got terminated.
Problems is, as instances are already terminated I am not able to find... | Amazon AWS: How to get details of terminated EC2 instance from instance id |
You are attempting to download a copy of your repo fromexample.com(resolves to93.184.216.34).Think about where the main copy of your repo is. It'snoton example.com, is it?You need to use the actual address of your repo, not the example url given in the BFG docs.It's possible you're not using a Git hosting service, in w... | I was trying to useBFG Repo-Cleanerto remove a large file from git history, but can't get it work. Please help!I downloaded the latest BFGbfg-1.12.12.jarThen I tried to clone a fresh copy of my repo:$ git clone --mirror git://example.com/some-big-repo.gitHere comes the problem, it says:fatal: unable to connect to examp... | Can't get bfg-repo-cleaner work |
If you really need to get necessary info to use with ssh, you could extract those info viaDownward API, and make sure that your pods are ssh-enabled as well.IMHO, the intuitive way to check for deployment status is using readiness check. In that case, you could run a bash script to check for specific environment variab... | I have created 4 containers within a single namespace( All have bash ).
I want to ssh to container1 from container2.I want to get some values like: the "image" used to create the container, any "Environment variables" etc.How can I achieve it?Thanks in advance.Pritish | kubernetes: ssh to a pod from another pod in same namespace |
0
I resolved the issue by replacing /usr/sbin/sendmail -t with /bin/mailx. For more information (and with due credit to "HBruijn"), see the following link: https://serverfault.com/questions/1147855/amanda-backup-software-using-postfix-generates-invalid-sendmail-option-s
... |
I recently updated postfix on my CentOS 6 server to support a new email relay, and everything is working except my Amanda backup software, which is no longer sending status emails. When I run "amreport" on the command line, it gives me these errors:
sendmail: invalid option -- 's'
sendmail: invalid option -- 's'
send... | Amanda backup software using postfix generates invalid sendmail option '-s' |
Git is a distributed system and there is a copy of all the code in all repos that the code has been committed or pushed into. References between repositories are minimal text flags that mention where a merge commit came from. There is no real link between them.
I have deleted many forks on github in the past with no i... |
Background: I have a situation similar to this but the solution there doesn't solve my problem. On GitHub I forked a fork of a project:
Original -> SomeonesFork -> MyFork
I forked from SomeonesFork in order to clean up some changes they had made and send a pull request back to the original repo. Since then I have als... | Is it safe to delete a fork of a GitHub repo, when the original refers to mine? |
If all you need is plugin and theme why not init git on wp-content folder?and add ignore files on upload folder and plugin based folder that changes a lot like cache. Ignoring some .md might even reduce your repo size.some .gitignore like:/upload/
/cache/
*.md | I've been trying to find a way to use git with Wordpress in a way that I can have a local directory and sync it to Github without disorganizing XAMPP's file structure. I had the idea of initializing the repo in the theme folder but then I realized that a lot of plugin's keep pertinent data in directories outside the th... | Using Git with Wordpress |
If you receive multiple questions in theQUESTIONsection of a single query, just returnFORMERR(RCODE = 1) to the entire query.As you've found, the semantics for theRCODEfield in these circumstances are not defined.I did write an Internet Draft (i.e. a pre-publication RFC) that described a possible solution but the probl... | Some DNS request may contain multiple queries, and my server isNOTRecursion Available, if i can only answer part of the queries, how do i respond?To be more specify, how to set theRCODE? | How to response a DNS request when only part of the queries is answered? |
I don't think so. Even if you want to share the dashboard to
someone, you need to create a user in QuickSight. Any more than 1
user will be charged by AWS.The dashboard cannot be public and you need to login to view the
dashboard. If it was public, you could have embedded it in your
webpage as an iframe. But you canno... | I need to display live interactive graphs based on customer data present in MySQL,for generating the graphs, I am planning to use Amazon Quick Sight but i would like to know whether the generated graphs can be integrated with my web application UI ?
Datasource MYSQL is hosted in AWS.Any other better design solution is ... | Is it possible to integrate Amazon QuickSight dashboard graphs to a web application? |
There is a long-standing feature request for this. Thelatest entrysuggestskubectl get po --all-namespaces | gawk 'match($3, /([0-9])+\/([0-9])+/, a) {if (a[1] < a[2] && $4 != "Completed") print $0}'for finding pods that are running but not complete.There are a lot of other suggestions in the thread that might work as w... | We have deployed a few pods in cluster in various namespaces. I would like to inspect and identify all pod which is not in a Ready state.master $ k get pod/nginx1401 -n dev1401
NAME READY STATUS RESTARTS AGE
nginx1401 0/1 Running 0 10mIn above list, Pod are showing in Running status bu... | Identify pod which is not in a Ready state |
I don't think they have ever said publicly. Kubernetes does natively support group claims in OIDC tokens however as you said, there are none in Google tokens so we know it isn't using that. Given the deep integration between GCP IAM and GKE it's generally assumed the Google internal fork has some custom admission contr... | I would like to understand one thing on OpenId Connect and GKE to better manage IAM and RBAC.I cannot find any info on this:I'm Project Owner in my GCP projectAfter applyinggcloud container clusters get-credentials $CLUSTER --zone $ZONEmy.kube.confis populated.I can get myid_tokengcloud config config-helper --format=js... | How does GKE map my IAM user account into k8s Group |
3
Based on https://github.com/facebook/jest/issues/1456#issuecomment-587529051
You need to delete the initialized Firebase app which "renders this app unusable and frees the resources of all associated services".
afterAll(() => {
firebase.app().delete();
});
Or use the... |
While running my unit tests with GitHub Actions for my app cerate by Create React App using the Firebase Emulator I get an error
Jest did not exit one second after the test run has completed.
This usually means that there are asynchronous operations that weren't stopped in your tests. Consider running Jest with `--de... | Jest did not exit one second after the test run has completed when using GitHub Actions and Firebase |
I had this same issue. It was a bug in the alpine linux dns resolution system...we worked around it changing the base image from node to centosShareFollowansweredAug 20, 2019 at 18:15TechmagoTechmago38044 silver badges1818 bronze badgesAdd a comment| | I am using axios npm package to invoke an kubernetes service in Google Kubernetes Environment. My NodeJS application is hosted as a Kubernetes Deployment along with this another service which it is trying to invoke.I get ENOTFOUND error when this service is invoked , my code looks something like this , where some-servi... | Why am I getting ENOTFOUND error with Axios on Kubernetes |
The hard limit for Dictionary<TKey, TValue> is due to the private field entries, which has the type Entry[]. In this case Entry is a struct:
private struct Entry {
public int hashCode;
public int next;
public TKey key;
public TValue value;
}
The minimum size of Entry is 4*4, which could happen if TKey and TVa... |
Related to this:
System.OutOfMemoryException because of Large Dictionary
I am getting OutOfMemoryException when I let .NET manage my dictionary. The exception thrown in resize method. So I was trying to avoid resizing by providing large number as a capacity. Naturally I tried to start from int.MaxValue just to make su... | How to figure out the max value for capacity parameter passed to Dictionary constructor to avoid OutOfMemoryException? |
The above avoids having to malloc and free the buffer in each
iteration. Would the above work?In principle, yes.Would it improve performance?Probably. Memory allocation and deallocation isn't without latency.Is it good practice or is there a better way to do this?Generally speaking, yes. Lots of widely used GPU accel... | I am writing an code that does calculations with thousands of sparse matrices on the GPU using cuSparse. Because memory is limited on the GPU, I need to treat them one by one as the rest of the memory is taken up by other GPU variables and dense matrices.My work flow (in pseudo-code) is the following:for (i=0;i<1000;i+... | Can I allocate more memory than necessary with cudaMalloc to avoid reallocating? |
It is built using GithubPagesservice.Hereis the link to this repository. | What blog software and theme is used athttp://mmcgrana.github.com/?(e.g. Wordpress with Forest theme)I'm confused because it's hosted at github.com but am unaware they provide their users with blog software. | What blog software & theme is used at |
It doesn’t make sense to have cities lookup (city names are not unique very often). Let’s say you have city with the name London - where do you place it on the map?There are 29 places around the world called London. | I am using grafana with Prometheus as datasource (this last one sends me a list of cities - no coords, only city names) and I am using the geomap Visualizations but there are only 3 options in Gazetteer option : Countries, USA States and Airports.I would like to match with cities in the world .. Is there a way to add c... | Grafana : how to use Geomap lookup with cities |
This will give you the array of registered instance ID in a target group. When you have target ARN why you using target ID? so I am skipping target ID and using just target ARN.
aws elbv2 describe-target-health --target-group-arn ${TG} --query 'TargetHealthDescriptions[*].Target.Id'
|
We are trying to get the state of a registered target (instance) in a target group. This can be done with the command aws elbv2 describe-target-health --target-group-arn ${TG} --targets Id=${ID},Port=${PORT}, reference. We are able to get the PORT via the aws ecs describe-tasks --cluster $CLUSTER --tasks $task comma... | how to get list of registered targets in AWS target group via CLI |
On the pull request create page there's a checkbox (checked by default) that is "Allow edits from maintainers". This enables maintainers to push changes to your branch before merging.Here's what it looks like in the current UI:ShareFollowansweredOct 14, 2017 at 0:33anthony sottileanthony sottile65.3k1515 gold badges16... | On Github - So I forked a branch, made some changes, and submitted a pull request. Before the pull request was accepted, I noticed a collaborator of the original branch pushed a commit into my forked branch. Then the pull request was accepted with the changes I made and he made in my forked branch. How is is possibl... | Github - original author pushing to forked branch |
7
You can just put it in brackets:
locals {
bucket_name = (var.bucket_name == ""
? "hoge-${formatdate("YYYYMMDDHHmmss", timestamp())}"
: var.bucket_name)
}
Share
Improve this answer
Follow
... |
I want to know the way to separate terraform expressions into multiple lines because they're sometimes too long if in 1 line.
terraform's version I use
$ terraform version
Terraform v0.14.2
long expression example : If the bucket name is not specified, create a new bucket name. If specified, use it.
locals {
bu... | Is there any way to separate terraform's expression into multiple lines? |
Your first look should be atServices.With services you can start a container runningMySQLorPostgresand run tests which will connect to it. | I am considering porting a legacy pipeline that builds and tests Docker/OCI images into GitLab CI/CD. I already have a GitLab Runner in a Kubernetes cluster and it's registered to a GitLab instance. Testing a particular image requires running certain commands inside (for running unit tests, etc.). Presumably this could... | Tests that require orchestration of multiple containers in GitLab CI/CD |
You have to commit the changes and then push them. After that, pull the changes in your local repository.In your server:git add .
git commit -m "Your message"
git pushIn your local repository:git pull | One of the resources have updated and made changes directly on the server of our site.What should I do to make sure that my local and git are all updated with server files?When I did agit statusafter an ssh on my server, I get this:-On branch master
# Changed but not updated:
# (use "git add <file>..." to update what... | How do I update my git when files are changed directly on the server? |
[Cache-Control:max-age] and [Expires] in Http are doing the same thing and that is a reason why they are redundant.
But there are still some big differences between them, [Cache-Control] is http/1.1 standard and Expires is http/1.0. If client browser does not support http/1.1 Cache-Control will be ignored, and that is ... | Can someone clarify this statement about caching.https://developers.google.com/speed/docs/best-practices/cachingsaysIt is redundant to specify bothExpiresandCache-Control: max-age, or to specify bothLast-ModifiedandETag.Then later it saysThe fingerprinting mechanism allows the server to set theExpiresheader to exactly ... | Setting both Expires and Cache-Control: max-age |
Issue in integrating sonarqube analysis with Ci buildAccording to the error messageAPI GET ‘/api/server/version’ failed, it seems your Azure DevOps agent fails to connect to the SonarQube URL.If you are using Hosted agent, it could not access to your localhost SonarQube server. So, you have to use private agent.If you ... | I am trying to run sonarqube analysis with Ci build.
I have added the tasks ‘Prepare analysis on Sonarqube’ and ‘Run Code Analysis’ in my vsts build definition . I am getting the below error upon queuing the build:[SQ] API GET ‘/api/server/version’ failed, error was: {“code”:“ENOTFOUND”,“errno”:“ENOTFOUND”,“syscall”:“... | Issue in integrating sonarqube analysis with Ci build |
Git has the full history locally. You need not pull or clone to get the files back. As it sounds like you haven't committed the deletions,git reset --hardis one of the standard recommended ways to get them back. This just restores the working directory (and index of "staged changes to be committed") to the revision ... | Greetings,I recently set up a GitHub repository and installed Git on my system.
Until now I have used AnkhSVN and Tortoise with Google code repositories and I am having some difficulties understanding some parts of Git.For testing this system I tried deleting a couple of files from my project folder and used pull and ... | How do I clone a GitHub repository and auto overwrite existing contents? |
The basic example to listallcommits is inapi/LogCommandTest.java#L83Iterator<RevCommit> log = git.log().all().call().iterator();You can Mark a commit to start graph traversal fromLogCommand add(AnyObjectId start):LogCommand.java#L163-L191You can get the ref of a branch withRef Repository.getRef(final String name)lib/Re... | I use egit-github library to load all commits from GitHub, now I need to list all commits from a specific branch other than master, how I can do with this library | Get the list of commits with specific branch (egit-github lib) |
I have nothing better than:
location /watch {
return 302 $scheme://$host?vid=$arg_v;
}
It avoids using if and rewrite, which is always a good thing. If you need to check for v= in the URI, then use if, but rather test whether $arg_v is empty.
However it redirects even if there is no argument or if it is empty. I ... |
In nginx, I am redirecting a URL with a param like:
www.example.com/watch?v=12345678 -> www.example.com?vid=12345678
So I wrote the following configuration for the same:
location /watch {
if ($args ~* v=(.*)) {
set $args vid=$1;
rewrite ^/watch?(.*)$ / redirect;
}
}
Everything is working as... | URL redirect with params in Nginx |
Without resorting to cut'n'paste of the link that @MYYN posted, I suspect this is because the optimisations that the JVM performs are not static, but rather dynamic, based on the data patterns as well as code patterns. It's likely that these data patterns will change during the application's lifetime, rendering the ca... |
The canonical JVM implementation from Sun applies some pretty sophisticated optimization to bytecode to obtain near-native execution speeds after the code has been run a few times.
The question is, why isn't this compiled code cached to disk for use during subsequent uses of the same function/class?
As it stands, eve... | Why doesn't the JVM cache JIT compiled code? |
Git has its own proxy.To reset git proxy:git config --global https.proxy ""
git config --global http.proxy ""To reset system proxy:On Ubuntu, you can set proxy by usingexport http_proxy=""
export https_proxy=""
export all_proxy=""Then rungit clone | I am working on a TensorFlow tutorial at the moment and need to download the source code. When I rungit clone ..., however, I get the following error:C:\Git\cmd>git clone https://github.com/tensorflow/nmt/
Cloning into 'nmt'...
fatal: unable to access 'https://github.com/tensorflow/nmt/': Could not resolve proxy: aprox... | Could not resolve proxy - git clone |
DocumentDB supports TLS protocol. It worked for me when I1/ downloaded the TLS public key usingwget https://s3.amazonaws.com/rds-downloads/rds-combined-ca-bundle.pem2/ changed the parameterssl=truetotls=truein the connection string,3/ and updated the params to connect() method.const uri = 'mongodb://<user>:<password>@<... | Hello I am just trying to connect to my documentDb using mongoose; hosted on AWS. From my local pc, I am try to do it like:const URI = 'mongodb://username:npassword@docdb-2022-05-31-18-46-43.cluster-cnyrbefiq91q.eu-west-2.docdb.amazonaws.com:27017/?ssl=true&replicaSet=rs0&readPreference=secondaryPreferred&retryWrites=f... | Connecting to AWS documentDB using mongoose giving error: 'MongoParseError: option ssl_ca_certs is not supported' |
I'd suggest having a simple service that loads a file from your server to say the app is online, until that file is loaded your app is offline so you won't make the Ajax call in the first place, maybe have the service poll your server given the importance of knowing the status throught your app session. | I have a RESTful web service that returns a list of products. I have an Angular app that calls this service via Ajax. What I want to do is:check whether the list of products is in localStorage, if so, display this on the screen, then make the Ajax call in the background and refresh the screen when this service returns.... | Display data from localStorage cache, then update with AJAX result from service |
The error message is quite clear. When the container tries to run it is not able to find properties file.
You need to add config.properties file to your docker image.
ADD path_to_config_file/config.properties /data/config/config.properties
NOTE: path_to_config_file refers to the file path in your local where you are ... |
Here my DockerFile :-
FROM openjdk:10
ENV AQUILA_HOME /data/config
#USER root
#VOLUME /tmp
ADD a2i-web-1.0.0-SNAPSHOT.jar app.jar
#RUN bash -c 'touch /app.jar'
ENTRYPOINT ["java","-jar","app.jar"]
My jar is spring boot application which refers configuration file from some directory [/data/config/config.properties]
I ... | File not found exception while running DockerFile |
Since you are using a node.js server you can just invoke your lambda directly with the AWS JavaScript SDK(https://www.npmjs.com/package/aws-sdk). This way you don't have to worry about using API Gateway.
Invoking from your server is as simple as:
var AWS = require('aws-sdk');
// you shouldn't hardcode your keys in pr... |
I am going through a basic AWS on how to create a lambda function: Using AWS Lambda with Amazon S3
In this example we are creating an image re-sizing service, one way to trigger it is to listen for some image to be pushed to a S3 bucket and then lambda function will be executed.
But I am trying to understand how to in... | Invoke amazon lambda function from node app |
There's only one container named exactly "foo", so use:$ docker container inspect fooinstead, and you can format the output to get whatever data you need from that. E.g. to show the current status and image:$ docker container inspect foo -f '{{.State.Status}} {{.Config.Image}}'
running foo_image:latestFrom the comments... | docker container ls -f name=fooreturns all containers which have names that containfoo. This means it also return a container namedfoobar, for example. How can I filter for all the containers named exactlyfoo? | How to make docker container ls -f name filter by exact name? |
After searching, I create a file outside the container calledclient_max_body_size.confwith the contentsclient_max_body_size 25m;(or whatever) and bind mount it into your nginx-proxy container:docker run -d --name nginx-proxy -v /var/run/docker.sock:/tmp/docker.sock \
-v $ /client_max_body_size.conf:/etc/nginx/conf.... | In my architecture I use the /jwilder/nginx-proxy as a proxy server in my docker and then I installed 3 WordPress websites with MySQL and WordPress.They are working well but /jwilder/nginx-proxy has a default configuration upload limit to 2MB but my WordPress template is about 20MB.When I am trying to upload this templ... | How can I change the docker jwilder/nginx-proxy upload limits? |
docker login -u USERNAME -p TOKEN docker.pkg.github.com
docker push docker.pkg.github.com/liufa/testdockerandk8/dockerandk8test:0.1Here, replaceUSERNAMEwith your username andTOKENwith the personal access token generated withread/write/delete:packagesenabledhttps://github.com/settings/tokens | I am using Windows 10 Pro and trying to publish a docker image to GitHub by using PowerShelltagandpushcommands.docker tag 8a3e8abca3b6 docker.pkg.github.com/liufa/testdockerandk8/dockerandk8test:0.1docker push docker.pkg.github.com/liufa/testdockerandk8/dockerandk8test:0.1However, I am getting the following errorunauth... | Your token has not been granted the required scopes to execute this query. The 'id' field requires one of the following scopes: ['read:packages'], |
You need to add aCountedAspectas a bean, then the metrics are created when you call the method:@Configuration
@EnableAspectJAutoProxy(proxyTargetClass = true)
public class Config {
@Bean
CountedAspect countedAspect(MeterRegistry registry) {
return new CountedAspect(registry);
}(Can't remember why w... | How @Counted works?
I have added @Counted annotation on my method in Controller and expecting to see how many hits are coming to the controller. But i cannot see metrics added onto the url http://localhost:8080/actuator/prometheus.@Counted(value = "counted.success.test",description = "testCounter") | How @Counted works in spring boot? |
6
That's not how memory management works on Unix/Linux. You don't allocate memory to processes, they just request more virtual memory as they need it.
Maybe what you're talking about is the process's virtual memory limit. You can use the shell's ulimit command to set vario... |
I am using a CAD program on 64 bit Fedora 16. At one point the program suddenly crashes and completely exits. My initial guess is that there is not enough memory available for that program to perform that operation and it quits. To test it, I want to allocate more memory to that particular program and in doing so I am... | how to allocate more memory to a process in linux |
<div class="s-prose js-post-body" itemprop="text">
<p>The error message is little misleading. The problem was not that there was invalid character, but the network was misconfigured. I had one LAN interface and one WLAN interface.</p>
<p>LAN interface connects to a router A which forward requests to router B which was ... | <div class="s-prose js-post-body" itemprop="text">
<p>When I go <code>docker pull hello-world</code> I get the below error message:</p>
<p><code>Error response from daemon: error parsing HTTP 408 response body: invalid character '<' looking for beginning of value: "<html><body><h1>408 Request Time-... | Docker error: HTTP 408 response body: invalid character '<' looking for beginning of value |
To control the master key the Function host uses on startup - instead of generating random keys - prepare our ownhost_secrets.jsonfile like{
"masterKey": {
"name": "master",
"value": "asGmO6TCW/t42krL9CljNod3uG9aji4mJsQ7==",
"encrypted": false
},
"functionKeys": [{
"name": "d... | I am playing around with an Http Triggered Azure Functions in a Docker container. Up to now all tutorials and guides I found on setting this up configure the Azure Function with theauthLevel"set toanonymous.After readingthis blogcarefully it seems possible (although tricky) to also configure other authentication levels... | Http Trigger Azure Function in Docker with non anonymous authLevel |
This works for me:SELECT
$__timeGroup(created_at, '1d') AS time,
COUNT(id) as 'New Users'
FROM [db].[user]
GROUP BY $__timeGroup(created_at, '1d')
ORDER BY 1 | I'm trying display the user growth per day using Grafana Time Series with SQL Server. However I found the documentation to be unhelpful and my queries are incorrect.The following returns a constant value of 1 for every day. What do I need to change to display the number of new users created per day?Thank you very much ... | Grafana User Growth Time Series with SQL Server |
I discovered that Kaspersky antivirus started using self-signed certificates in their "Web Anti-Virus" feature which caused Git to complain.In order to work with the remote in any way over HTTP (push, fetch, pull, etc.) Kaspersky Web Anti-Virus needs to be disabled or that particular Git repo added to the exclusions li... | I just started getting this error when trying to push my changes. I don't know what changed on my system and there should not be any self-signed certs in this connection.Git has been uninstalled and re-installed. Git appears to be using the proper bundle:http.sslcainfo=C:/Program Files/Git/mingw64/ssl/certs/ca-bundle.c... | Git - "SSL certificate issue: self signed certificate in certificate chain" |
I managed to do it.
First, I added ports forwarding in the configuration of my mariadb container.I executed the following docker commandsdocker-compose stop
docker-compose up -dlater, I added a new rule in the VM port forwarding rulesNow I'm able to connect to the database from my windows client programShareFollowanswe... | I work on PC under Windows 7 x64.I installed the OracleVM, then installed there Ubuntu 18.04. In Ubuntu, I installed Docker and created and run an environment with PHP, Nginx, and MariaDB and I managed to set up a Drupal 8 site there. All works successfully, and I managed to get access to the site from a browser on my ... | Getting access to database in the docker container on VM |
OpenShift is a PaaS layer on top of Kubernetes, so there really isn't a difference in the Kubernetes part of the stack. However, OpenShift embeds many Kubernetes (and Etcd) binaries in their distribution, so it isn't always 100% obvious that Kubernetes is somewhere underneath because you don't interact the the stock se... | I understand that openshift comes with its own kubernetes and etcd. But i have already installed kubernetes and etcd. What should i do? what is the differences between Openshift kubernetes an google's? Thanks. | Difference between openshift kubernetes version and googles kubernetes |
I figured out that the region value was not being filled causing the replace function to not act appropriately.. | I'm learning how to use the replace function within go templating but I'm running into an issue.I have my template build this:- cpuRequest: 200m
etcdMembers:
- instanceGroup: master-us-east-1a
name: us-east-1a
- instanceGroup: master-us-east-1d
name: us-east-1d
- instanceGroup: master-us-eas... | Replace a value with a new value in template |
0
Please try with below process might be it will help!!
Adding State Parameter will help for oauth2_proxy
State Parameter
State parameter will reserve the state prior to authentication request and pass random generated state value in request to authenticate and in call ba... |
I am running a Kubernetes Cluster with an Nginx-ingress fronting couple of web apps. Because Nginx doesn't support SSO/OIDC by default, I use an oauth_proxy for authentication.
In detail I use oauth2_proxy (https://github.com/pusher/oauth2_proxy) with Azure AD.
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
... | Nginx Ingress pass whole url to oauth proxy as Redirect |
Unfortunately, only Closures have "Capture List" feature like[weak self]. For nested functions, You have to use normalweakorunownedvariables.func myInstanceMethod() {
weak var _self = self
func nestedFunction(result : Bool) {
_self?.anotherInstanceMethod()
}
functionExpectingClosure(nestedFunct... | With closures I usually append[weak self]onto my capture list and then do a null check onself:func myInstanceMethod()
{
let myClosure =
{
[weak self] (result : Bool) in
if let this = self
{
this.anotherInstanceMethod()
}
}
functionExpectingClosure(myClosure)
}... | Is self captured within a nested function |
There are no files to commit, so git is returning a non-zero error code. This leads fabric to believe that the previous command failed, so it aborts.
To be honest, unless you're absolutely certain that git is mistaken, and there are changes to commit, then I'm tempted to believe that your script is not actually malfu... |
I'm using Fabric to run an ANT task & then upload to GitHub. The script has worked, but not consistently so its difficult to understand why.
I've been reading on here that the process in Fabric is;
git add
git commit
git push
But I keep seeing this output;
# On branch master
# Your branch is ahead of 'origin/master'... | Can't commit from Fabric script for GitHub |
You can always usegit push origin master --forceto forceoriginto be an exact copy of your local machine.USE WITH CAUTION! | I have committed all changes and pushed to GitHub right after that, but the source viewer on GitHub is only showing the source from three hours ago.$ git status# On branch masternothing to commit, working directory cleanUpdategit push originThis updated the the GitHub repository, for some reason. So that fixed my probl... | Git commit, git push to GitHub, nothing more to commit, but GitHub is not updated |
Drain first node.sudo docker node update --availability drain worker2Verify No containers are on drained node.sudo docker ps #on worker2Upgrade docker engine.Check node in swarm manager.sudo docker node lsChange availablity to Active.sudo docker node update --availability ActiveRepeat the steps for other nodes.ShareFol... | Docker changes so fast so I'm trying to find out if a Docker Swarm (swarm mode) cluster can be upgraded. For instance say I am running 1.12 and I have a 3 node cluster running services. Let's also say Docker 1.13 comes out and I want to upgrade the engines that make up the swarm cluster. Is there anyway to do this t... | Upgrading swarm mode cluster |
Command line with git log:
git log --decorate -- filename
For every commit in the log --decorate prints tags and branches the commit belongs to.
For example, log for file README.rst from SQLObject:
$ git log --decorate -4 -- README.rst
commit 39b3cd4
Author: Oleg Broytman <[email protected]>
Date: Sat Feb 24 19:10:... |
Is it possible to show the history of a file - with each commit showing which tags it belongs to?
Every time we upgrade our database, one file is updated with the new schema version. Often, I'll have a database (which has the schema version in a settings table) and I'd like to look at the commits (with that version nu... | Show file history with tags? |
If you are worried about the size of returning a structure like this as a result of an init function then I would not (caveats to that statement (you can always measure if you are unsure)).
All modern compilers are already doing RVO and NRVO optimization. As a result even if you return by value a copy is not being mad... |
I've got the following variable (simplified case):
std::array<std::array<float, 4>, 4> matrix;
I need to return this variable from a function in my program. I could either use std::unique_ptr or return it as a value (automatic vs dynamic memory)
Since the size of a float on my platform is 4 bytes, and there are 16 po... | What is the practical limit regarding size concerning efficiency of automatic variables in C++? |
U can use IIS dynamic compression for WCF messages.
Read next threads/articles:Enabling dynamic compressionGZip compression with WCF hosted on IIS7 | I have a Silverlight application in which I call my WCF service to get data from the database. If there is a small number of records then it's working fine, but if there are many records then it throws a System.OutOfMemory exception.I have traced it in a WCF error log file. Are there any ways to compress the data which... | OutOfMemory exception when large number of records is sent from WCF to Silverlight |
"Github Deployments" is really just an API you can use to alert Github about deployments (start/finish) and the Deployments Dashboard to view activity. In order for anything to show up there you first need to actually trigger a Github deployment event and specify an environment. Put the action I've linked below at the... |
Good morning!
I have been playing around with GitHub Actions to build and deploy to multiple stages. Works like a charm.
But deployments in GitHub has been hard to overview.
I have access to Environments, which is where I’ve added some secrets.
I found this article in the docs, but I can’t find it in my public repo. h... | Access to GitHub Deployments Dashboard |
With nginx you don't need rewrites at all.upstream domain_server { server localhost:8000 fail_timeout=0; }
proxy_set_header Host domain.com;
proxy_set_header X-forwarded-for $proxy_add_x_forwarded_for;
server {
listen 80 default_server;
location / {
proxy_pass http://domain_server/userdomain/$http_h... | I need these two types of rewrites:subdomain.domain.com => domain.com/website/subdomainotherdomain.com => domain.com/userdomain/otherdomain.comMy problem is that I want the user to seesubdomain.domain.com, andotherdomain.com, not the redirected version. My current rewrite in nginx works, but the user's URL shows the re... | nginx subdomain and domain rewrite w proxy pass |
12
No, reputation meachanism.
53,994 ++ green colour indicate current user added lines and 39,917 -- red colour indicate current user remove or replace lines.
Share
Improve this answer
Follow
edited Jul 13, ... |
Example.
In this page, for each contributor, there is a text description just like:
fengyuanchen 54 commits / 53,994 ++ / 39,917 --
What does the two number 53,994 ++ / 39,917 -- and the signs ++, -- mean? I couldn't find any tips in github help or google.
I guess they are something like stackoverflow's reputation me... | What does the two number mean in Github contributor graph page? |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.