This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| version: 0.0 | |
| Resources: | |
| - TargetService: | |
| Type: AWS::ECS::Service | |
| Properties: | |
| TaskDefinition: "arn:aws:ecs:us-east-1:982383527471:task-definition/rails-example:4" | |
| LoadBalancerInfo: | |
| ContainerName: "rails-example" | |
| ContainerPort: 3000 |
We can make this file beautiful and searchable if this error is corrected: Unclosed quoted field in line 5.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name,registry,ship_class,description | |
| USS Defiant,NCC-75633,Defiant,Formerly the USS São Paulo. Assigned to space station Deep Space Nine. Participates in the Battle of Cardassia. | |
| SS Vico,NAR-18834,Oberth,"Research vessel that was in service with Starfleet in the mid-24th century. This ship was on loan to a civilian agency, and was given a civilian registry. Vico operated out of Starbase 514. In 2368, the Vico explored an astronomical formation known as a black cluster. Found derelict by Enterprise-D." | |
| USS Raven,NAR-32450,Undetermined,Science and exploration vessel used by the Hansens for exploration of the Delta Quadrant where Seven of Nine was assimilated by the Borg. | |
| USS YorktownUSS Enterprise (from 2286),NCC 1717,Constitution refit,"Disabled by whale probe, then possibly salvaged and renamed Enterprise; although no onscreen evidence supports this. Command given to James T. Kirk following his demotion to Captain. Primary setting for Star Trek V: The Final Frontier and Star Trek VI: The Undiscovered Country, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require 'aws-sdk-ec2' | |
| require 'pry' | |
| class GitpodToRds | |
| def self.run sg_id:, ip_protocol:, from_port:, to_port:, description:, ip_address: | |
| raise "ip address must not be blank" if ip_address.nil? | |
| cidr_ip_range = "#{ip_address}/32" | |
| client = GitpodToRds.ec2_client | |
| sg = GitpodToRds.describe_security_group client: client, sg_id: sg_id |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| I am attempting to install packages for NodeJS that reference a CodeCommit repository that resides in different AWS Account from a different AWS Organization. | |
| I am receive the error "unable to access" | |
| =========================== | |
| npm ERR! Error while executing: | |
| npm ERR! /usr/bin/git ls-remote -h -t https://git-codecommit.us-east-1.amazonaws.com/v1/repos/my_package | |
| npm ERR! | |
| npm ERR! fatal: unable to access 'https://git-codecommit.us-east-1.amazonaws.com/v1/repos/my_package/ ': The requested URL returned error: 403 | |
| =========================== |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| mkdir test_video | |
| cd test_video | |
| ffmpeg -f lavfi -i testsrc=duration=3600:size=256x144:rate=24 t1.mpg | |
| cp t1 t1.mpg | |
| cp t1 t2.mpg | |
| cp t1 t3.mpg | |
| cp t1 t4.mpg | |
| cp t1 t5.mpg | |
| cp t1 t6.mpg | |
| cp t1 t7.mpg |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require "test/unit" | |
| # remove the first and last letter of a string | |
| # if there is less than 2 characters return zero. | |
| def quartered value | |
| raise ArgumentError, 'Argument is not a string' unless value.is_a? String | |
| return value unless value.size > 2 | |
| value[0] = '' | |
| value.chop | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| source 'https://rubygems.org' | |
| git_source(:github) do |repo_name| | |
| repo_name = "#{repo_name}/#{repo_name}" unless repo_name.include?("/") | |
| "https://github.com/#{repo_name}.git" | |
| end | |
| gem 'rspec' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # spec/hello_spec.rb | |
| require_relative '../hello' | |
| RSpec.describe Hello do | |
| context "#world" do | |
| it { expect(Hello.world).to eql 'world' } | |
| end | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| source 'https://rubygems.org' | |
| git_source(:github) do |repo_name| | |
| repo_name = "#{repo_name}/#{repo_name}" unless repo_name.include?("/") | |
| "https://github.com/#{repo_name}.git" | |
| end | |
| gem 'minitest' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require 'minitest/autorun' | |
| require_relative './hello' | |
| describe Hello do | |
| describe "#world" do | |
| it "should return world" do | |
| Hello.world.must_equal 'world' | |
| end | |
| end | |
| end |