Git Product home page Git Product logo

Comments (7)

brorio avatar brorio commented on August 23, 2024

Got a bit further:

scripts/01_main.sh
\e[32mINFO :\e[39m Checking project directories
\e[32mINFO :\e[39m Loading default settings and secrets

------------------------- GIT REPO $(FY $PRJ_NAME) -----------------
On branch master
nothing to commit, working tree clean
/Users/macos/Documents/r-ec2/ipromx/scripts/03_check_settings.sh: line 23: mapfile: command not found
\e[31mERROR:\e[39m Not on branch \e[36m(master)\e[39m. Exiting.

Running:
GNU bash, version 4.4.23(1)-release (x86_64-apple-darwin17.5.0)

from aws-lambda-r.

MikeBadescu avatar MikeBadescu commented on August 23, 2024

GNU bash, version 4.4.23(1)-release (x86_64-apple-darwin17.5.0)

mapfile: command not found

This is very strange, mapfile should be part of Bash 4.0+ ... I do not know why you are getting this particular error (it may depend on your configuration ?). I am not also sure why you are seeing the escape characters \e[32m - these should be colors in the terminal (when configured properly).

I would recommend to try this project first on a Linux machine (e.g. in EC2 or a local VM) to see how it works. Then identify any macos related issues.

Currently I cannot test the scripts on OSX; thus any insights / issues / solutions will be appreciated.

from aws-lambda-r.

brorio avatar brorio commented on August 23, 2024

Added: #!/usr/local/bin/bash at the top of all sh files to solve the mapfile error.

Now I am stuck again:

scripts/01_main.sh
INFO : Checking project directories
INFO : Loading default settings and secrets

------------------------- GIT REPO $(FY $PRJ_NAME) -----------------
On branch master
nothing to commit, working tree clean
INFO : On branch (master)
INFO : Branch (master) is clean.
WARN : Not all commits on branch (master) pushed to remote or not tracking changes.

------------------------- AWS CREDENTIALS --------------------------
ERROR: Your AWS access key is: MISSING. Exiting.

Using AWS_PRFL="--profile myprofile" in settings_default.sh

But that does not seem to be enough.

Tried to add the keys to setup_user.sh

AWS_ACCESS_KEY_ID=XXXX..
AWS_SECRET_ACCESS_KEY=XXXXX...

No luck..

from aws-lambda-r.

MikeBadescu avatar MikeBadescu commented on August 23, 2024

Look in secrets_default.sh too. The keys to provide are IAM_ACCESS_KEY_ID and IAM_SECRET_ACCESS_KEY (to avoid the same name as the local AWS env variables). They are needed to perform AWS operations while on EC2.

from aws-lambda-r.

brorio avatar brorio commented on August 23, 2024

Thanks!
Yes I am switching to Ubunu Linux now.

from aws-lambda-r.

brorio avatar brorio commented on August 23, 2024

I'm still seem to getting forward on OSX:

cripts/01_main.shINFO : Checking project directories
INFO : Loading default settings and secrets

------------------------- GIT REPO $(FY $PRJ_NAME) -----------------
On branch master
nothing to commit, working tree clean
INFO : On branch (master)
INFO : Branch (master) is clean.
WARN : Not all commits on branch (master) pushed to remote or not tracking changes.

------------------------- AWS CREDENTIALS --------------------------
Your AWS access key is: ********NKNQ
Your AWS secret access key is: ********J2vN
AWS Account ID: ********1270
AWS Region: us-west-1

------------------------- EC2 INSTANCE -----------------------------
No Custom AMI present, using Default AMI: ami-4fffc834
Instance Type: t2.micro
ERROR: Subnet ID: subnet-MISSING. Exiting.

from aws-lambda-r.

MikeBadescu avatar MikeBadescu commented on August 23, 2024

ERROR: Subnet ID: subnet-MISSING. Exiting.

You need to provide values otherwise the variables will default to a value of $MISSING.

Some familiarity with AWS is needed. The comments in the .sh files (in the settings/ directory) and the documentation in the doc/ folder help somehow. Finally, there is the "auto setup" created by following step 6 of the main README.

from aws-lambda-r.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.