One Paragraph of project description goes here
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.
| exports.handler = async (event, context) => { | |
| const shop = event.queryStringParameters.shop | |
| const redirectUri = event.queryStringParameters.redirect | |
| const apiKey = process.env.SHOPIFY_API_KEY | |
| const scopes="read_content,write_content,read_products,read_themes,write_themes" | |
| if (shop) { | |
| const installUrl = 'https://' + shop + | |
| '/admin/oauth/authorize?client_id=' + apiKey + | |
| '&scope=' + scopes + |
| node { | |
| def ak = "<AWS_ACCESS_KEY>" | |
| def id = "${env.JOB_NAME}-${env.BUILD_ID}" | |
| def wd = pwd() | |
| def run = "docker run --rm -u `id -u jenkins` -v ${wd}:/tmp/${id} -w=/tmp/${id} -e AWS_ACCESS_KEY_ID=${ak} -e AWS_SECRET_ACCESS_KEY=${env.ask} --entrypoint=/go/bin/terraform hashicorp/terraform:full" | |
| git credentialsId: '<CREDS_ID>', url: '<GIT_URL>' | |
| withCredentials([[$class: 'StringBinding', credentialsId: '<CREDS_ID_2>', variable: 'ask']]) { |