-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update: support for multiple PHP versions and Docker
- Loading branch information
Showing
5 changed files
with
279 additions
and
167 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
/vendor/ | ||
.phpunit.cache/ | ||
composer.lock |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
# Use an official PHP image as a starting point | ||
FROM php:8.3-cli | ||
|
||
# Download and install Composer | ||
RUN php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" && \ | ||
php composer-setup.php --install-dir=/usr/local/bin --filename=composer && \ | ||
php -r "unlink('composer-setup.php');" | ||
|
||
# Install the zip extension | ||
RUN apt-get update \ | ||
&& apt-get install -y libzip-dev zip \ | ||
&& docker-php-ext-install zip | ||
|
||
# Install the zip extension for alpine linux distributions | ||
#RUN apk update && \ | ||
# apk add --no-cache libzip-dev zip && \ | ||
# docker-php-ext-install zip | ||
|
||
# Set the working directory to the root of your project | ||
WORKDIR /app | ||
|
||
# Copy the composer.json and composer.lock file to the container | ||
COPY composer.json ./ | ||
|
||
# Install the dependencies | ||
RUN composer install | ||
|
||
# Copy the rest of your application to the container | ||
COPY . . | ||
|
||
# Default command to run when container starts | ||
CMD ["php", "index.php"] |
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,44 +1,44 @@ | ||
{ | ||
"name": "labsmobile/sms-php", | ||
"description": "Send SMS messages through the LabsMobile platform and the PHP library.", | ||
"type": "library", | ||
"license": "MIT", | ||
"keywords": [ | ||
"php", | ||
"composer", | ||
"sms", | ||
"httpclient", | ||
"sms-api", | ||
"sms-messages", | ||
"sms-client", | ||
"sms-notifications", | ||
"smsapi", | ||
"sms-php", | ||
"labsmobile" | ||
], | ||
"autoload": { | ||
"psr-4": { | ||
"Labsmobile\\SmsPhp\\": "src/" | ||
} | ||
}, | ||
"autoload-dev": { | ||
"psr-4": { | ||
"Labsmobile\\SmsPhp\\Tests\\": "tests/" | ||
} | ||
}, | ||
"authors": [ | ||
{ | ||
"name": "LabsMobile", | ||
"email": "support@labsmobile.com", | ||
"homepage": "https://www.labsmobile.com/" | ||
} | ||
], | ||
"require-dev": { | ||
"phpunit/phpunit": "^8.5" | ||
}, | ||
"require": { | ||
"php": "^7.2.0", | ||
"guzzlehttp/guzzle": "^7.8", | ||
"ext-json": "*" | ||
"name": "labsmobile/sms-php", | ||
"description": "Send SMS messages through the LabsMobile platform and the PHP library.", | ||
"type": "library", | ||
"license": "MIT", | ||
"keywords": [ | ||
"php", | ||
"composer", | ||
"sms", | ||
"httpclient", | ||
"sms-api", | ||
"sms-messages", | ||
"sms-client", | ||
"sms-notifications", | ||
"smsapi", | ||
"sms-php", | ||
"labsmobile" | ||
], | ||
"autoload": { | ||
"psr-4": { | ||
"Labsmobile\\SmsPhp\\": "src/" | ||
} | ||
}, | ||
"autoload-dev": { | ||
"psr-4": { | ||
"Labsmobile\\SmsPhp\\Tests\\": "tests/" | ||
} | ||
}, | ||
"authors": [ | ||
{ | ||
"name": "LabsMobile", | ||
"email": "support@labsmobile.com", | ||
"homepage": "https://www.labsmobile.com/" | ||
} | ||
], | ||
"require-dev": { | ||
"phpunit/phpunit": "^4.8 || ^5.7 || ^6.0 || ^7.0 || ^8.0" | ||
}, | ||
"require": { | ||
"php": ">=5.4.0, <=8.3.0", | ||
"guzzlehttp/guzzle": "^5.0 || ^6.0 || ^7.0 || ^7.2", | ||
"ext-json": "*" | ||
} | ||
} |
Oops, something went wrong.