### Get Builds cURL Example Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/reference/api/docs.html Example of how to retrieve builds using cURL. ```curl curl -X get "https://localhost:8084//v2/builds/{buildMaster}/builds/**" ``` -------------------------------- ### Orca Success Output Example Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/community/gardening/spin-contrib.md This is an example of the expected output when the Orca service starts successfully in IntelliJ. ```bash INFO 18111 --- [main] com.netflix.spinnaker.orca.Main: [] Started Main in 11.123 seconds (JVM running for 11.933) ``` -------------------------------- ### Run Prometheus Server-Only Installation Script Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/monitoring/prometheus.md Executes the installation script for a server-only Prometheus setup on virtual machines. Use --gateway= for gateway deployments, --gce for GCE instance discovery, or refer to cloud provider documentation for multi-VM setups. ```bash /opt/spinnaker-monitoring/third_party/prometheus/install.sh \ --server_only ``` -------------------------------- ### Check Azure CLI Installation Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/install/providers/azure.md Verify that the Azure CLI is installed on your system. This is a prerequisite for following the setup guide. ```bash az --version ``` -------------------------------- ### Install Redis Server on MacOS Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/install/environment.md Installs and starts the Redis server on MacOS using Homebrew. Redis is required for Spinnaker development. ```bash brew install redis brew services start redis ``` -------------------------------- ### Install gcloud SDK Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/tutorials/codelabs/gce-source-to-prod/index.md Installs the Google Cloud SDK. Follow the prompts for configuration. ```bash curl https://sdk.cloud.google.com | bash ``` -------------------------------- ### Example: Add Single Plugin Repository Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/user/plugins/index.md An example of adding the 'spinnaker-plugin-examples' repository, pointing to its plugins.json file on GitHub. ```bash hal plugins repository add spinnaker-plugin-examples \ --url=https://raw.githubusercontent.com/spinnaker-plugin-examples/examplePluginRepository/master/plugins.json ``` -------------------------------- ### Install Bundler and Dependencies Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/README.md Installs the Bundler gem and then installs all project dependencies defined in the Gemfile for the Spinnaker.io project. ```sh cd spinnaker.github.io gem install bundler bundle install ``` -------------------------------- ### Install Git on Ubuntu Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/install/environment.md Installs the Git version control system on Ubuntu using apt-get. ```bash sudo apt-get install git ``` -------------------------------- ### Install and Configure Nginx Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/tutorials/codelabs/hello-deployment/index.md Commands to install Nginx and open the default configuration file for editing. ```bash sudo apt-get install nginx sudo vim /etc/nginx/sites-enabled/default ``` -------------------------------- ### Manage Spin CLI Lifecycle Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/reference/halyard/commands.md Provides subcommands for managing the spin CLI, such as installation. Use 'hal spin install' to install the spin CLI. ```bash hal spin [subcommands] ``` -------------------------------- ### Example: Multiple Plugin Repositories Configuration Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/user/plugins/index.md An example of a repositories.json file listing several plugin repositories, including internal and external sources. ```json [ { "id": "spinnaker-plugin-examples", "url": "https://raw.githubusercontent.com/spinnaker-plugin-examples/examplePluginRepository/master/plugins.json" }, { "id": "my-company-internal-plugins", "url": "https:////plugins.json" }, { "id": "my-plugins", "url": "https://github.com/aimeeu/pluginRepository/blob/master/plugins.json" } ] ``` -------------------------------- ### Install Halyard Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/quickstart/halyard-gce.md Installs Halyard on the Halyard host VM. This involves downloading the installation script and executing it, followed by sourcing the bash profile. ```bash curl -O https://raw.githubusercontent.com/spinnaker/halyard/master/install/stable/InstallHalyard.sh sudo bash InstallHalyard.sh . ~/.bashrc ``` -------------------------------- ### CI Build Service Interface Implementation Example Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/developer/extending/integrate-your-CI/index.md An example of how a new CI service should be implemented in 'igor' by extending the 'CiBuildService' interface. ```java public class SomeCiService implements CiBuildService[..] ``` -------------------------------- ### Install Halyard Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/install/halyard.md Execute the downloaded Halyard installation script with sudo privileges. Default answers are usually suitable if prompted. ```bash sudo bash InstallHalyard.sh ``` -------------------------------- ### Install kubectl Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/quickstart/halyard-gke/index.md Installs the latest stable version of kubectl on your system. Ensure kubectl is in your PATH. ```bash KUBECTL_LATEST=$(curl -s https://storage.googleapis.com/kubernetes-release/release/stable.txt) curl -LO https://storage.googleapis.com/kubernetes-release/release/$KUBECTL_LATEST/bin/linux/amd64/kubectl chmod +x kubectl sudo mv kubectl /usr/local/bin/kubectl ``` -------------------------------- ### Install awscli Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/install/providers/kubernetes-v2/aws-eks.md Installs the AWS Command Line Interface (AWS CLI) using apt. Verifies the installation by displaying the awscli version. ```bash # Install the awscli sudo apt install python-pip awscli # Verify the installation aws --version ``` -------------------------------- ### Install Netcat on Ubuntu Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/install/environment.md Installs the netcat utility for reading from and writing to network connections on Ubuntu. ```bash sudo apt-get install netcat ``` -------------------------------- ### Install Halyard Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/quickstart/halyard-gke/index.md Downloads and installs the Halyard daemon. After installation, source your bash profile to make Halyard commands available. ```bash curl -O https://raw.githubusercontent.com/spinnaker/halyard/master/install/debian/InstallHalyard.sh sudo bash InstallHalyard.sh . ~/.bashrc ``` -------------------------------- ### Install OpenJDK 8 JDK on Ubuntu Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/install/environment.md Installs OpenJDK 8 JDK on Ubuntu by adding a PPA, updating package lists, and then installing the JDK. ```bash sudo add-apt-repository ppa:openjdk-r/ppa sudo apt-get update sudo apt-get install openjdk-8-jdk ``` -------------------------------- ### Start Nginx Service Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/tutorials/codelabs/hello-deployment/index.md Command to start the Nginx service after configuration. ```bash sudo service nginx start ``` -------------------------------- ### Scaffold Script Interaction Example Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/developer/plugins/frontend.md Example of user input and output during the frontend plugin scaffold process. ```shell npx: installed 117 in 6.229s Enter the short name for your plugin (default: myplugin): my-plugin Directory to scaffold into (default: my-plugin-deck): Deck plugin scaffolded into my-plugin-deck Installing dependencies using 'yarn' and 'npx check-peer-dependencies --install' ... ``` -------------------------------- ### Install Halyard Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/install/providers/kubernetes-v2/aws-eks.md Downloads and configures Halyard, used for installing and managing Spinnaker. Verifies the installation by displaying the Halyard version. ```bash # Download and configure Halyard curl -O https://raw.githubusercontent.com/spinnaker/halyard/master/install/debian/InstallHalyard.sh sudo useradd halyard sudo bash InstallHalyard.sh sudo update-halyard # Verify the installation hal -v ``` -------------------------------- ### Install Halyard Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/tutorials/codelabs/appengine-source-to-prod/index.md Download and install Halyard, the command-line tool for configuring, installing, and managing Spinnaker. This is a prerequisite for configuring Spinnaker. ```bash curl -O https://raw.githubusercontent.com/spinnaker/halyard/master/install/debian/InstallHalyard.sh sudo bash InstallHalyard.sh ``` -------------------------------- ### Install Telepresence on macOS Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/community/gardening/spin-contrib.md Use Homebrew Cask to install osxfuse and then Homebrew to install Telepresence on macOS. ```bash brew cask install osxfuse brew install datawire/blackbird/telepresence ``` -------------------------------- ### Install Stackdriver Dashboards Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/monitoring/stackdriver.md Installs the Spinnaker monitoring daemon and third-party components, then runs the Stackdriver dashboard installation script. Requires setting the STACKDRIVER_API_KEY environment variable. ```bash export STACKDRIVER_API_KEY= sudo apt-get update -y sudo apt-get install spinnaker-monitoring-daemon -y sudo apt-get install spinnaker-monitoring-third-party -y /opt/spinnaker-monitoring/third_party/stackdriver/install.sh --dashboards_only ``` -------------------------------- ### Install Halyard Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/developer/dev-env/provider-setups/aws-dev-setup.md Downloads and installs Halyard, the Spinnaker configuration and deployment tool. Ensure you source ~/.bashrc after installation to update your environment. ```bash curl -O https://raw.githubusercontent.com/spinnaker/halyard/master/install/debian/InstallHalyard.sh sudo bash InstallHalyard.sh source ~/.bashrc hal -v ``` -------------------------------- ### Install Curl on Ubuntu Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/install/environment.md Installs the curl utility for transferring data with URLs on Ubuntu. ```bash sudo apt-get install curl ``` -------------------------------- ### Install eksctl Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/install/providers/kubernetes-v2/aws-eks.md Downloads and configures eksctl, a command-line tool for managing EKS clusters. Verifies the installation by displaying eksctl help information. ```bash # Download and configure eksctl curl --silent --location "https://github.com/weaveworks/eksctl/releases/download/latest_release/eksctl_$(uname -s)_amd64.tar.gz" | tar xz -C /tmp sudo mv /tmp/eksctl /usr/local/bin # Verify the installation eksctl help ``` -------------------------------- ### Install and Configure kubectl and aws-iam-authenticator Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/install/providers/kubernetes-v2/aws-eks.md Installs kubectl for Kubernetes management and aws-iam-authenticator for cluster authentication. Verifies installations by displaying help information. ```bash # Download and install kubectl curl -LO https://storage.googleapis.com/kubernetes-release/release/$(curl -s https://storage.googleapis.com/kubernetes-release/release/stable.txt)/bin/linux/amd64/kubectl chmod +x ./kubectl sudo mv ./kubectl /usr/local/bin/kubectl # Verify the installation of kubectl kubectl help # Download and install aws-iam-authenticator curl -o aws-iam-authenticator https://amazon-eks.s3-us-west-2.amazonaws.com/1.13.7/2019-06-11/bin/linux/amd64/aws-iam-authenticator chmod +x ./aws-iam-authenticator mkdir -p $HOME/bin && cp ./aws-iam-authenticator $HOME/bin/aws-iam-authenticator && export PATH=$HOME/bin:$PATH echo 'export PATH=$HOME/bin:$PATH' >> ~/.bashrc #Verify the installation of aws-iam-authenticator aws-iam-authenticator help ``` -------------------------------- ### Clouddriver Startup Log Example Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/developer/dev-env/provider-setups/aws-dev-setup.md Example output showing the successful startup of the Clouddriver service, including Spinnaker's ASCII art logo and log messages. ```text # Clouddriver start up msg displays after all gradle tasks are run ... > Task :clouddriver-web:run ___ __ /\_ \ /\ \ ___\]/\ \ ___ __ __ \_\ \ /'___\\ \ \ / __`\/\ \/\ \ /'_` \ /\ \__/ \_\ \_/\[L\ \ \ \_\ \/\ \L\ \ \ \____/\____\ \____/\ \____/\ \___,_ \/____/\/____/\___/ \/_/ \/_/__,_ / __ /\ \ \_\ \ _ __ /\_\ __ __ __ _ __ /'_` \/\`'__\/\ \/\ \/\ \ /'__`\/\`'__\ /\ \L\ \ \ \/ \ \ \ \_/ |/\ __/\ \ \/ \ \___,_\]/_/ \/_/\___/ \ \____\ \_/ \/__,_ /\/_/ \/_/\__/ \/____/\/_/ 2020-06-04 21:09:28.940 INFO 29524 --- [ main] b.c.PropertySourceBootstrapConfiguration : Located property source: CompositePropertySo urce {name='configService', propertySources=[]} 2020-06-04 21:09:28.946 INFO 29524 --- [ main] com.netflix.spinnaker.clouddriver.Main : The following profiles are active: composite ,test,local ... ``` -------------------------------- ### Get Clusters cURL Example Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/reference/api/docs.html Example of how to retrieve cluster details using cURL. ```curl curl -X get "https://localhost:8084//applications/{application}/clusters/{account}/{clusterName}" ``` -------------------------------- ### Get Job Config cURL Example Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/reference/api/docs.html Example of how to retrieve job configurations using cURL. ```curl curl -X get "https://localhost:8084//v2/builds/{buildMaster}/jobs/**" ``` -------------------------------- ### Start and Enable Redis Server Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/quickstart/faq.md Use these commands to start the Redis server and ensure it runs on boot. This is necessary if Redis is not available at the default address. ```bash sudo systemctl enable redis-server && sudo systemctl start redis-server ``` -------------------------------- ### Install Git on MacOS Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/install/environment.md Installs the Git version control system on MacOS using Homebrew. ```bash brew install git ``` -------------------------------- ### Complete Pipeline Template Example Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/user/pipeline/pipeline-templates/create.md This is a full example of a pipeline template JSON, demonstrating the schema, variables, and a parameterized wait stage. ```json { "schema": "v2", # Reference to the MPTv2 schema "variables": [ { "type": "int", "defaultValue": 42, "description": "The time a wait stage shall pauseth", "name": "timeToWait" # This is the name that's referenced in the SpEL expression later } ], "id": "newSpelTemplate", # Main identifier to reference this template from instance "protect": false, "metadata": { "name": "Variable Wait", "description": "A demonstrative Wait Pipeline.", "owner": "example@example.com", "scopes": ["global"] }, "pipeline": { # A "normal" pipeline definition. "lastModifiedBy": "anonymous", "updateTs": "0", "parameterConfig": [], "limitConcurrent": true, "keepWaitingPipelines": false, "description": "", "triggers": [], "notifications": [], "stages": [ { "waitTime": "${ templateVariables.timeToWait }", # Templated field. "name": "My Wait Stage", "type": "wait", "refId": "wait1", "requisiteStageRefIds": [] } ] } } ``` -------------------------------- ### Get Load Balancer cURL Example Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/reference/api/docs.html Example cURL request to retrieve a specific load balancer by its name. ```curl curl -X get "https://localhost:8084//loadBalancers/{name}?provider=" ``` -------------------------------- ### Clone Sample Application Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/tutorials/codelabs/pubsub-to-appengine/index.md Clones the Python "Hello World" sample application from GitHub. ```bash git clone https://github.com/GoogleCloudPlatform/python-docs-samples.git ``` -------------------------------- ### Install Spinnaker (Open Source) Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/developer/plugins/testing/deck-plugin.md Installs the open source version of Spinnaker using the no_auth_install script with the -o option. ```bash ./minnaker/scripts/no_auth_install.sh -o ``` -------------------------------- ### Download Halyard Installer for Debian/Ubuntu Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/install/halyard.md Use this command to download the Halyard installation script for Debian or Ubuntu systems. ```bash curl -O https://raw.githubusercontent.com/spinnaker/halyard/master/install/debian/InstallHalyard.sh ``` -------------------------------- ### Install OpenJDK 11 on macOS Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/community/gardening/spin-contrib.md Use Homebrew to tap the AdoptOpenJDK repository and install OpenJDK 11 on macOS. ```bash brew tap AdoptOpenJDK/openjdk brew cask install adoptopenjdk11 ``` -------------------------------- ### Get Cluster Load Balancers cURL Example Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/reference/api/docs.html Example of how to retrieve cluster load balancers using cURL. ```curl curl -X get "https://localhost:8084//applications/{application}/clusters/{account}/{clusterName}/{type}/loadBalancers" ``` -------------------------------- ### Example Spinnaker Pod Status Output Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/community/gardening/spin-contrib.md Example output showing the status of Spinnaker pods, indicating that they are running. ```bash NAME READY STATUS RESTARTS AGE minio-0 1/1 Running 0 27m spin-clouddriver-7569597b8b-zbw6c 1/1 Running 0 27m spin-deck-7777b5d98b-w7bcl 1/1 Running 0 27m spin-echo-5c9db8d898-b9pkb 1/1 Running 0 27m spin-front50-59f8695cd5-xtw4c 1/1 Running 0 27m spin-gate-bfd4c488c-hn45h 1/1 Running 0 27m spin-orca-784b867dd8-pz6js 1/1 Running 0 27m spin-redis-6745f98fb9-fxj7l 1/1 Running 0 27m spin-rosco-5b69d6556-9dgxx 1/1 Running 0 27m ``` -------------------------------- ### Get Jobs For Build Master cURL Example Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/reference/api/docs.html Example of how to retrieve jobs for a build master using cURL. ```curl curl -X get "https://localhost:8084//v2/builds/{buildMaster}/jobs" ``` -------------------------------- ### Get Account Details cURL Example Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/reference/api/docs.html Example of how to retrieve an account's details using the getAccountUsingGET API endpoint. ```curl curl -X get "https://localhost:8084//credentials/{account}" ``` -------------------------------- ### Orca Initialization Log Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/developer/plugins/testing/deck-plugin.md Successful Orca startup with plugin loading messages indicates the plugin is recognized. ```bash 020-05-12 16:03:44.274 INFO 6973 --- [0.0-8083-exec-1] o.a.c.c.C.[Tomcat].[localhost].[/] : [] Initializing Spring DispatcherServlet 'dispatcherServlet' INFO 6973 --- [0.0-8083-exec-1] o.s.web.servlet.DispatcherServlet : [] Initializing Servlet 'dispatcherServlet' INFO 6973 --- [0.0-8083-exec-1] o.s.web.servlet.DispatcherServlet : [] Completed initialization in 16 ms ``` ```bash INFO 90843 --- [main] org.pf4j.AbstractPluginManager: [] Plugin 'Armory.RandomWaitPlugin@unspecified' resolved INFO 90843 --- [main] org.pf4j.AbstractPluginManager: [] Start plugin 'Armory.RandomWaitPlugin@unspecified' INFO 90843 --- [main] i.a.p.s.wait.random.RandomWaitPlugin: [] RandomWaitPlugin.start() ``` -------------------------------- ### Get Application Load Balancers cURL Example Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/reference/api/docs.html Example cURL request to retrieve a list of load balancers for a specific application. ```curl curl -X get "https://localhost:8084//applications/{application}/loadBalancers" ``` -------------------------------- ### Get All Load Balancers cURL Example Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/reference/api/docs.html Example cURL request to retrieve a list of all load balancers for a given cloud provider. ```curl curl -X get "https://localhost:8084//loadBalancers?provider=" ``` -------------------------------- ### Verify Halyard Installation Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/install/halyard.md Check if Halyard was installed correctly by running the version command. Ensure 'hal' is in your PATH if the command fails. ```bash hal -v ``` -------------------------------- ### Example CI Service Implementation Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/developer/extending/integrate-your-CI/index.md A placeholder for a custom CI service implementation that would integrate with Igor's build service. ```java public class SomeCiService implements CiBuildService[...] ``` -------------------------------- ### Get Accounts List cURL Example Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/reference/api/docs.html Example of how to retrieve a list of accounts using the getAccountsUsingGET API endpoint with various optional query parameters. ```curl curl -X get "https://localhost:8084//credentials?roles=&allowedAccounts=&email=&username=&firstName=&lastName=" ``` -------------------------------- ### Get Load Balancer Details cURL Example Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/reference/api/docs.html Example cURL request to retrieve the details of a specific load balancer using its account, region, and name. ```curl curl -X get "https://localhost:8084//loadBalancers/{account}/{region}/{name}?provider=" ``` -------------------------------- ### Run Documentation Site Preview with Docker Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/community/contributing/docs/local-clone.md Run a Docker container to preview your documentation changes locally. This mounts the current directory and maps port 4000. The '--incremental' flag speeds up rebuilds. ```bash docker run -it --rm --mount "type=bind,source=$(pwd),target=/code" \ -p 4000:4000 spinnaker/spinnaker.github.io-test --incremental ``` -------------------------------- ### Get Resource by ID Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/reference/api/docs.html Simple example to retrieve a specific resource using its unique identifier. ```javascript function getResourceById(url, id) { return fetch(`${url}/${id}`).then(handleApiResponse).catch(handleApiError); } ``` -------------------------------- ### Serve Spinnaker.io Site Locally with Jekyll Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/README.md Starts the Jekyll development server to preview the Spinnaker.io site locally. Use --incremental for faster rebuilds during development. ```sh bundle exec jekyll serve --watch bundle exec jekyll serve --watch --incremental ``` -------------------------------- ### Example Redis Connection Exception in Clouddriver Log Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/developer/dev-env/provider-setups/aws-dev-setup.md This is an example of a JedisConnectionException indicating a failure to obtain a resource from the Redis pool, often seen when Clouddriver fails to start correctly. The root cause is usually an earlier exception in the log. ```java 2019-08-14 19:30:34.381 ERROR 24799 --- [gentScheduler-1] c.n.s.c.r.c.ClusteredAgentScheduler : Unable to run agents redis.clients.jedis.exceptions.JedisConnectionException: Could not get a resource from the pool at redis.clients.util.Pool.getResource(Pool.java:53) ~[jedis-2.9.3.jar:na] at redis.clients.jedis.JedisPool.getResource(JedisPool.java:226) ~[jedis-2.9.3.jar:na] at com.netflix.spinnaker.kork.jedis.telemetry.InstrumentedJedisPool.getResource(InstrumentedJedisPool.java:60) ~[kork-jedis-5.11.1.jar:5.11.1] at com.netflix.spinnaker.kork.jedis.telemetry.InstrumentedJedisPool.getResource(InstrumentedJedisPool.java:26) ~[kork-jedis-5.11.1.jar:5.11.1] at com.netflix.spinnaker.kork.jedis.JedisClientDelegate.withCommandsClient(JedisClientDelegate.java:45) ~[kork-jedis-5.11.1.jar:5.11.1] at com.netflix.spinnaker.cats.redis.cluster.ClusteredAgentScheduler.acquireRunKey(ClusteredAgentScheduler.java:178) ~[cats-redis.jar:na] at com.netflix.spinnaker.cats.redis.cluster.ClusteredAgentScheduler.acquire(ClusteredAgentScheduler.java:131) ~[cats-redis.jar:na] at com.netflix.spinnaker.cats.redis.cluster.ClusteredAgentScheduler.runAgents(ClusteredAgentScheduler.java:158) ~[cats-redis.jar:na] at com.netflix.spinnaker.cats.redis.cluster.ClusteredAgentScheduler.run(ClusteredAgentScheduler.java:151) ~[cats-redis.jar:na] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [na:1.8.0_222] at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) [na:1.8.0_222] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) [na:1.8.0_222] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) [na:1.8.0_222] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [na:1.8.0_222] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [na:1.8.0_222] at java.lang.Thread.run(Thread.java:748) [na:1.8.0_222] Caused by: java.lang.IllegalStateException: Pool not open ... ``` -------------------------------- ### Include Specific Metrics Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/monitoring/index.md Example configuration to include only two specific metrics by their literal names. This is useful for a minimal monitoring setup. ```yaml monitoring: filters: meters: byLiteralName: - controller.invocations - jvm.memory.used ``` -------------------------------- ### Start Deck with API Host Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/developer/plugins/testing/deck-plugin.md Run the Deck development server, specifying the API host for Gate and disabling authentication. ```bash cd deck yarn API_HOST={my-workstation-ip}:8084 AUTH_ENABLED=false yarn start ``` -------------------------------- ### Download and Prepare Aptly Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/tutorials/codelabs/hello-deployment/index.md Downloads the Aptly binary and makes it executable for the Jenkins user. ```bash sudo su - jenkins cd ~ wget https://dl.bintray.com/smira/aptly/0.9.5/debian-squeeze-x64/aptly chmod +x aptly ``` -------------------------------- ### Get Halyard Deployment Details Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/reference/halyard/commands.md Retrieves details about the current Spinnaker installation. Use the `--service-name` parameter to specify which service to inspect. ```bash hal deploy details --service-name ``` -------------------------------- ### Configure Google Pub/Sub Settings Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/triggers/google.md Set up Spinnaker's Google Pub/Sub integration by enabling support and adding a subscription with your credentials. ```bash # See 'Credentials' section above SERVICE_ACCOUNT_DEST= # See 'A Pub/Sub Subscription' section above MESSAGE_FORMAT= PROJECT= SUBSCRIPTION= # You can pick this name, it's meant to be human-readable PUBSUB_NAME=my-google-pubsub ``` ```bash hal config pubsub google enable ``` ```bash hal config pubsub google subscription add $PUBSUB_NAME \ --subscription-name $SUBSCRIPTION \ --json-path $SERVICE_ACCOUNT_DEST \ --project $PROJECT \ --message-format $MESSAGE_FORMAT ``` -------------------------------- ### Get Current Snapshot using Curl Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/reference/api/docs.html This example shows how to fetch the current snapshot for a given application and account using a cURL command. Replace placeholders with actual values. ```curl curl -X get "https://localhost:8084//applications/{application}/snapshots/{account}" ``` -------------------------------- ### Create Google Service Account and Key Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/triggers/google.md Use these commands to create a service account with the Pub/Sub subscriber role and download its JSON key. ```bash SERVICE_ACCOUNT_NAME=spinnaker-pubsub-account SERVICE_ACCOUNT_DEST=~/.gcp/pubsub-account.json gcloud iam service-accounts create \ $SERVICE_ACCOUNT_NAME \ --display-name $SERVICE_ACCOUNT_NAME SA_EMAIL=$(gcloud iam service-accounts list \ --filter="displayName:$SERVICE_ACCOUNT_NAME" \ --format='value(email)') PROJECT=$(gcloud config get-value project) gcloud projects add-iam-policy-binding $PROJECT \ --role roles/pubsub.subscriber --member serviceAccount:$SA_EMAIL mkdir -p $(dirname $SERVICE_ACCOUNT_DEST) gcloud iam service-accounts keys create $SERVICE_ACCOUNT_DEST \ --iam-account $SA_EMAIL ``` -------------------------------- ### SSH Tunneling for Port Forwarding Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/monitoring/datadog.md Establishes an SSH tunnel to forward local ports 9090 and 3000 to the remote host. This is necessary for installing dashboards and accessing monitoring services during setup. ```bash ssh -L 9090:localhost:9090 -L 3000:localhost:3000 ``` -------------------------------- ### Get Snapshot History using Curl Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/reference/api/docs.html This example demonstrates how to retrieve the snapshot history for a given application and account using cURL. The 'limit' query parameter can be used to control the number of results. ```curl curl -X get "https://localhost:8084//applications/{application}/snapshots/{account}/history?limit="" ``` -------------------------------- ### Install Ruby and Bundler for deb-s3 Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/tutorials/codelabs/hello-deployment/index.md Installs Ruby, Bundler, and development dependencies required to install the deb-s3 gem. ```bash sudo apt-get install software-properties-common sudo apt-add-repository ppa:brightbox/ruby-ng sudo apt-get update sudo apt-get install build-essential ruby2.2 ruby2.2-dev zlib1g-dev liblzma-dev sudo gem install bundler ``` -------------------------------- ### Provision Spinnaker and Jenkins Instance Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/tutorials/codelabs/gce-source-to-prod/index.md Creates a Google Compute Engine instance pre-configured with Spinnaker, Jenkins, and aptly. Replace with your GCP project ID. ```bash MY_PROJECT= INSTANCE_NAME=spinnaker-codelab ZONE=us-east1-b gcloud compute instances create $INSTANCE_NAME \ --project $MY_PROJECT \ --zone $ZONE \ --image spinnaker-codelab \ --image-project marketplace-spinnaker-release \ --machine-type n1-highmem-4 \ --scopes cloud-platform \ --metadata startup-script=/var/spinnaker/startup/first_codelab_boot.sh,gce_account=my-google-account ``` -------------------------------- ### Install Yarn on macOS Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/community/gardening/spin-contrib.md Use Homebrew to install Yarn, which also installs Node.js if not already present, on macOS. ```bash brew install yarn ``` -------------------------------- ### Install Spin CLI on Linux Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/spin/index.md Download the latest Spin CLI binary for Linux, make it executable, and move it to a directory in your system's PATH. ```bash curl -LO https://storage.googleapis.com/spinnaker-artifacts/spin/$(curl -s https://storage.googleapis.com/spinnaker-artifacts/spin/latest)/linux/amd64/spin chmod +x spin sudo mv spin /usr/local/bin/spin ``` -------------------------------- ### Deploy Spinnaker using Helper Script Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/community/gardening/spin-contrib.md Use the provided deploy.sh helper script to install the open-source version of Spinnaker. Ensure the SPIN_FLAVOR variable is set to 'oss'. ```shell SPIN_FLAVOR=oss ./deploy.sh ``` -------------------------------- ### Azure CLI Login and Subscription Setup Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/install/storage/azs.md Log in to your Azure account and set the active subscription for subsequent commands. ```bash az login az account list az account set --subscription ``` -------------------------------- ### Migrate Halyard from Debian to JAR Installation Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/install/halyard_migration.md Use this script to migrate your Halyard installation from a Debian package to a JAR-based installation. This process includes backing up your configuration, removing the old package, and installing the new version. ```bash HALYARD_BACKUP_PATH=$(hal backup create -q) sudo apt remove spinnaker-halyard/trusty-stable -y < /dev/null sudo rm /etc/apt/sources.list.d/halyard.list && sudo rm /etc/apt/sources.list.d/halyard.list.save sudo apt update curl -O https://raw.githubusercontent.com/spinnaker/halyard/master/install/debian/InstallHalyard.sh sudo bash InstallHalyard.sh hal backup restore --backup-path=$HALYARD_BACKUP_PATH ``` -------------------------------- ### Deploy Managing Account Infrastructure with Instance Profile Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/install/providers/aws/aws-ec2.md Use this command to deploy the managing account infrastructure when authenticating with an Instance Profile. Ensure the managing.yaml file is downloaded and optionally modified. ```bash curl -O -L https://spinnaker.io/downloads/aws/managing.yaml echo "Optionally add Managing account to the file downloaded as shown on line 158 in the SpinnakerAssumeRolePolicy section of the downloaded file." aws cloudformation deploy --stack-name spinnaker-managing-infrastructure-setup --template-file managing.yaml \ --parameter-overrides UseAccessKeyForAuthentication=false --capabilities CAPABILITY_NAMED_IAM --region us-west-2 ``` -------------------------------- ### Create a pipeline with manual trigger Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/reference/api/docs.html Example of creating a pipeline that is manually triggered. ```javascript function createManualTriggerPipeline(appName, pipelineName) { const pipelineConfig = { name: pipelineName, triggers: [ { type: 'manual' } ] }; // Implementation to create pipeline with config console.log(`Creating pipeline ${pipelineName} with manual trigger for app ${appName}`); return pipelineConfig; } ``` -------------------------------- ### Create Aptly Repository Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/tutorials/codelabs/hello-deployment/index.md Creates a new Aptly repository named 'hello' for managing Debian packages. ```bash ./aptly repo create hello ``` -------------------------------- ### Serve Documentation Site with Jekyll Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/community/contributing/docs/local-clone.md If Jekyll is installed, use this command to serve the documentation site locally. The '--watch' flag rebuilds the site when files change, and '--incremental' speeds up rebuilds. ```bash bundle exec jekyll serve --watch --incremental ``` -------------------------------- ### Install Prometheus Dashboards Only Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/monitoring/prometheus.md Installs only the Grafana dashboards for Prometheus. This command is used after the Prometheus server is configured and running, and requires port forwarding or the monitoring package to be installed. ```bash /opt/spinnaker-monitoring/third_party/prometheus/install.sh --dashboards_only ``` -------------------------------- ### Run Local Plugin Development Server Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/developer/plugins/frontend.md Start your local plugin development server and set the DEV_PROXY_HOST environment variable to point to the forwarded Deck instance. This enables hot-reloading and local development. ```shell DEV_PROXY_HOST=http://localhost:9001 yarn develop ``` -------------------------------- ### Install Node.js Version Manager and Yarn Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/developer/dev-env/provider-setups/aws-dev-setup.md Installs nvm, sets the Node.js version to stable, and installs Yarn globally. This is required for managing Node.js versions and dependencies. ```bash curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.11/install.sh | bash source ~/.bashrc nvm install stable npm install -g yarn ``` -------------------------------- ### Install Spin CLI on Windows Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/spin/index.md Download the latest Spin CLI executable for Windows, place it in a local directory, and update the user's PATH environment variable. ```powershell New-Item -ItemType Directory $env:LOCALAPPDATA\spin -ErrorAction SilentlyContinue Invoke-WebRequest -OutFile $env:LOCALAPPDATA\spin\spin.exe -UseBasicParsing "https://storage.googleapis.com/spinnaker-artifacts/spin/$([System.Text.Encoding]::ASCII.GetString((Invoke-WebRequest https://storage.googleapis.com/spinnaker-artifacts/spin/latest).Content))/windows/amd64/spin.exe" Unblock-File $env:LOCALAPPDATA\spin\spin.exe $path = [Environment]::GetEnvironmentVariable("PATH", [EnvironmentVariableTarget]::User) -split ";" if ($path -inotcontains "$env:LOCALAPPDATA\spin") { $path += "$env:LOCALAPPDATA\spin" [Environment]::SetEnvironmentVariable("PATH", $path -join ";", [EnvironmentVariableTarget]::User) $env:PATH = (([Environment]::GetEnvironmentVariable("PATH", [EnvironmentVariableTarget]::Machine) -split ";") + $path) -join ";" } ``` -------------------------------- ### subSequence(int start, int end) Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/reference/api/service-plugin-apis/orca-api/master/html/orca-api/com.netflix.spinnaker.orca.api.pipeline.models/-execution-status/index.html Returns a CharSequence that is a subsequence of this sequence. The subsequence starts at the specified start index and extends to the character at index end - 1. ```APIDOC ## subSequence(int start, int end) ### Description Returns a CharSequence that is a subsequence of this sequence. The subsequence starts at the specified start index and extends to the character at index end - 1. ### Method CharSequence ### Endpoint N/A (Method within an enum) ### Parameters #### Path Parameters - **start** (int) - The index of the first character to include in the subsequence. - **end** (int) - The index of the character *after* the last character to include in the subsequence. ### Response #### Success Response - **return value** (CharSequence) - The specified subsequence. ### Response Example ```json "COMPLETED" ``` ``` -------------------------------- ### Build Documentation Test Docker Image Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/community/contributing/docs/local-clone.md Build a Docker image for testing the documentation site locally. This command tags the image as 'spinnaker/spinnaker.github.io-test'. ```bash docker build --tag spinnaker/spinnaker.github.io-test . ``` -------------------------------- ### Set Start Time Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/reference/api/service-plugin-apis/orca-api/master/html/orca-api/com.netflix.spinnaker.orca.api.pipeline.models/-pipeline-execution/index.html Sets the start time of the pipeline execution. ```APIDOC ## setStartTime ### Description Sets the start time of the pipeline execution. ### Method abstract void ### Endpoint setStartTime(Long startTime) ### Parameters #### Path Parameters - **startTime** (Long) - Description of the startTime parameter ``` -------------------------------- ### Build Deck with Yarn Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/community/gardening/spin-contrib.md Build the Deck project using Yarn on the command line. You can ignore 'gyp' not found errors. ```bash cd deck yarn ``` -------------------------------- ### Install Datadog Dashboards Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/monitoring/datadog.md Installs pre-configured Datadog operational dashboards for Spinnaker. This script requires the spinnaker-monitoring-third-party package to be installed and may prompt for Datadog API and App keys. ```bash /opt/spinnaker-monitoring/third_party/datadog/install.sh --dashboards_only ``` -------------------------------- ### Example: Using the JAR template Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/reference/artifacts/from-build-triggers.md Export these properties from your CI job to use the Spinnaker-provided JAR template for artifact extraction. ```sh messageFormat=JAR ``` -------------------------------- ### Install Node.js v12.16.0 via NVM Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/install/environment.md Installs Node Version Manager (NVM) and then installs Node.js version 12.16.0. Follow the script's instructions to add NVM to your bash profile. ```bash curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.34.0/install.sh | bash # Follow instructions at end of script to add nvm to ~/.bash_rc nvm install v12.16.0 ``` -------------------------------- ### Configure a pipeline trigger Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/reference/api/docs.html Set up a trigger for a pipeline. This example shows how to configure a manual trigger. ```javascript function configurePipelineTrigger(pipelineId, triggerType) { // Implementation to configure trigger console.log(`Configuring ${triggerType} trigger for pipeline: ${pipelineId}`); } ``` -------------------------------- ### Install Yarn Globally Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/setup/install/environment.md Installs the Yarn package manager globally using npm. ```bash npm install -g yarn ``` -------------------------------- ### Publish Aptly Repository Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/tutorials/codelabs/hello-deployment/index.md Publishes the 'hello' Aptly repository, configuring it for amd64 architecture, 'main' component, and 'trusty' distribution, skipping GPG signing. ```bash ./aptly publish repo -architectures="amd64" -component=main -distribution=trusty -skip-signing=true hello ``` -------------------------------- ### Install Jenkins and Git Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/tutorials/codelabs/hello-deployment/index.md Installs necessary packages for Jenkins and Git on a Debian-based system. ```bash sudo apt-get update sudo apt-get upgrade sudo apt-get install openjdk-8-jdk wget -q -O - https://jenkins-ci.org/debian/jenkins-ci.org.key | sudo apt-key add - sudo sh -c 'echo deb http://pkg.jenkins-ci.org/debian binary/ > /etc/apt/sources.list.d/jenkins.list' sudo apt-get update sudo apt-get install jenkins git ``` -------------------------------- ### Start Telepresence for Orca Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/community/gardening/spin-contrib.md Initiate a Telepresence session to connect to the local Orca service. This requires changing to the Orca directory and using a specific Telepresence command with environment file. ```bash cd KUBECONFIG=~/.kube/garden.yaml telepresence --swap-deployment spin-orca --env-file .env-telepresence ``` -------------------------------- ### Install kubectl on macOS Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/community/gardening/spin-contrib.md Use Homebrew to install the kubectl command-line tool on macOS. ```bash brew install kubectl ``` -------------------------------- ### Canary Constraint Configuration Source: https://github.com/spinnaker/spinnaker.github.io/blob/master/guides/user/managed-delivery/environment-constraints/index.md This example demonstrates how to configure a Canary constraint, specifying analysis parameters, source cluster details, and regional deployment criteria. ```yaml constraints: - type: canary canaryConfigId: fn0rd5d1-6217-4fcf-aa3d-ce7f59af9cac beginAnalysisAfter: PT3M canaryAnalysisInterval: PT10M lifetime: PT90M marginalScore: 75 passScore: 90 capacity: 2 source: account: appaccount cloudProvider: aws cluster: app-prod regions: - us-east-1 - us-west-2 - eu-west-1 minSuccessfulRegions: 2 ```